// 从数据采集到策略回测的完整量化研究框架// End-to-end quantitative research framework: data ingestion to backtesting
四层管道设计,模块解耦,可扩展4-layer pipeline, modular, extensible
Wind Excel COM
Parquet 存储Wind Excel COM
Parquet Storage
10 种趋势跟踪
信号生成10 Trend-Following
Signal Generation
历史模拟
T+1 执行Historical Sim
T+1 Execution
三面板图表
性能报告3-Panel Charts
Performance Reports
基于 AUFI.WI 上海期货交易所黄金 Wind 指数 5 年历史数据回测 Backtested on AUFI.WI (Shanghai Futures Exchange Gold Index), 5-year historical data
| 策略Strategy | 累积收益Cum. Return | 年化收益Ann. Return | 最大回撤Max DD | 交易次数Trades | 胜率Win Rate | 平均收益Avg Return |
|---|---|---|---|---|---|---|
| TMA (5/20/60) | 120.66% | 26.99% | -22.30% | 50 | 33.33% | 25.11% |
| TMA (10/30/90) | 114.63% | 25.93% | -19.63% | 25 | 0.00% | -1.93% |
| EWMA Long-Only | 98.13% | 22.93% | -13.51% | 139 | 34.78% | 1.09% |
| Donchian (20) | 65.89% | 16.51% | -16.98% | 147 | 87.50% | 10.27% |
| Donchian (50) | 65.03% | 16.33% | -26.09% | 108 | 75.00% | 26.03% |
| EWMA Long-Short | 43.13% | 11.43% | -21.49% | 139 | 34.78% | 1.09% |
| RSI | -35.70% | -12.48% | -60.00% | 36 | 100.00% | 9.53% |
| MACD | -4.19% | -1.28% | -23.03% | 108 | 40.74% | 0.98% |
| Bollinger (20, 2.0) | -55.48% | -21.67% | -65.64% | 44 | 71.43% | 1.90% |
| Bollinger (20, 1.5) | -56.20% | -22.06% | -65.55% | 83 | 61.54% | 0.72% |
执行价格 = (开盘 + 收盘) / 2 · 信号日 T 生成,T+1 执行 Execution price = (open + close) / 2 · Signal at day T, executed at T+1
点击图片可放大查看Click to enlarge
价格穿越指数加权移动平均线时产生信号。提供多空和仅做多两个版本。Signals generated when price crosses the exponentially weighted moving average. Long-short and long-only variants.
利用快慢 EMA 差值及其信号线的交叉判断趋势方向。经典趋势跟踪指标。Fast/slow EMA difference and signal line crossovers for trend direction. A classic trend-following indicator.
价格突破 N 周期高点买入,跌破 N 周期低点卖出。海龟交易法则的核心。Buy on N-period high breakout, sell on N-period low breakdown. The core of the Turtle Trading system.
基于移动平均和标准差构建波动率通道,捕捉带宽收窄后的突破行情。Volatility bands based on moving average and standard deviation. Captures breakouts after bandwidth contraction.
利用超买超卖区间进行均值回归交易。适合震荡行情中的反转捕捉。Mean-reversion trading using overbought/oversold zones. Effective for catching reversals in ranging markets.
快中慢三条均线的排列关系判断趋势强度。多均线共振减少假信号。Triple moving average alignment for trend strength. Multi-MA resonance reduces false signals.
完整代码已托管在 GitHub,欢迎交流讨论 Full source code on GitHub — contributions and discussions welcome
GitHub →