Ta4j — Technical Analysis for Java

Welcome to the ta4j wiki, the living handbook for building, evaluating, and deploying TA-driven trading systems on the JVM.
The wiki follows a task-focused layout organized into clear sections:
Start Here
Get up and running quickly with essential guides:
- Home – Overview and quick navigation
- Getting Started – Installation, first steps, and your first strategy
- FAQ – Common questions and answers
- Release Notes – What’s new in each version, migration guides, and breaking changes
Core Concepts
Deep dives into ta4j’s fundamental building blocks:
Build Strategies
Learn to compose, test, and visualize trading strategies:
- Trading Strategies – Composing rules into complete strategies
- Backtesting – Evaluating strategy performance with historical data
- Charting – Creating professional charts with indicators, trading records, and analysis overlays
- Usage Examples – Real-world examples and patterns
Deploy & Operate
Take your strategies to production:
Contribute, report issues, and stay informed:
What’s new in 0.21.0
Release 0.21.0 (November 29, 2025) introduces unified return representation and enhanced oscillator coverage:
- Unified return representation system – Consistent formatting across all return-based criteria (multiplicative, decimal, percentage, logarithmic) via
ReturnRepresentation and ReturnRepresentationPolicy
- Ratio criteria standardization – All ratio-producing criteria now support
ReturnRepresentation for consistent dashboard and reporting outputs
- New oscillators –
TrueStrengthIndexIndicator, SchaffTrendCycleIndicator, and ConnorsRSIIndicator expand oscillator coverage
- Helper indicators –
PercentRankIndicator, DifferenceIndicator, and StreakIndicator for advanced indicator composition
- High-precision improvements –
DecimalNumFactory#exp now uses configured MathContext for better precision in exponential calculations
- Breaking changes – EMA indicators now return
NaN during unstable periods; DifferencePercentageIndicator deprecated in favor of PercentageChangeIndicator
Previous highlights (0.19)
Release 0.19 focused on production-ready workflows:
- Accelerated backtesting with
BacktestExecutor, runtime reports, and streaming top-K selection
- Strategy serialization & presets via
StrategySerialization and compact NamedStrategy formats
- Expanded indicator set including Renko brick helpers, MACDV, Net Momentum, and vote-based rules
- Deeper analytics like drawdown Monte Carlo simulation, commission impact, and capital utilization metrics
- Trendline and swing point analysis suite – Automated support/resistance detection with fractal and ZigZag swing indicators
- Unified data source interface – Consistent API for loading data from files, Yahoo Finance, Coinbase, and more
Browse the Release Notes for the complete changelog with migration guidance.
Need help or want to collaborate?
- Join the community Discord to discuss trading ideas, ask questions, or showcase projects
- Explore the ta4j-examples module for runnable samples referenced throughout the wiki
- Open issues or PRs in the main ta4j repository when you spot bugs or have improvements in mind