StockSharp.Strategies.0435_Ma_Cross_Dmi.py
v5.0.0Latest Stable
Any Framework
MA Cross + DMI Strategy (Python)
Published
Aug 7, 2025
1y ago
Total Downloads
732
732
Install
dotnet add package StockSharp.Strategies.0435_Ma_Cross_Dmi.py --version 5.0.0
No framework information available.
README
MA Cross + DMI Strategy (Python Version)
Trades a crossover of fast and slow exponential moving averages only when the Directional Movement Index confirms trend strength. By waiting for +DI or -DI to dominate while ADX rises above a key level, the system filters out weak crossovers.
This strategy can enter long or short positions and exits on opposing crossovers. ADX filtering helps the method stay out of ranging periods where moving averages frequently whipsaw.
Details
- Entry Criteria:
- Long: Fast EMA crosses above slow EMA, +DI > -DI, and ADX above the key level.
- Short: Fast EMA crosses below slow EMA, -DI > +DI, and ADX above the key level.
- Exit Criteria:
- Opposite crossover or manual stop.
- Indicators:
- Two EMAs (periods 10 and 20)
- Directional Movement Index (length 14, ADX smoothing 14)
- Stops: None by default; can use StartProtection.
- Default Values:
Ma1Length= 10Ma2Length= 20DmiLength= 14AdxSmoothing= 14KeyLevel= 20
- Filters:
- Trend following
- Works on intraday to swing timeframes
- Indicators: EMA, DMI
- Stops: Optional
- Complexity: Basic
Adoption Assessment
A verified publisher signal is available. Assess fit from the package's supported frameworks, license and dependency graph rather than popularity alone.
No SPDX license expression is published. Review the license text and your organisation's policy before redistribution.No target framework metadata is available. Confirm compatibility in a representative project before standardising on this package.
Related Guides & Workflows
Learn how to evaluate, integrate, or audit this package in your .NET project.