Data Provenance / Citation Trail
Documentation: Documentation
Request: Redacted request URL
Schema: timestamp, open, high, low, close, volume
Real data required: True
Synthetic data: False
Externally sourced input: True
Citation note: Alpha Vantage documentation describes TIME_SERIES_DAILY as returning daily open, high, low, close, and volume data. TIME_SERIES_DAILY_ADJUSTED additionally includes adjusted close and split/dividend fields.
Metric Formulas
| Metric | Computed By | Formula |
|---|---|---|
| controller_score | scripts.compare_results | total_return * 100 + sharpe * 0.10 - max_drawdown * 100 - trade_penalty |
| max_drawdown | risk.risk_engine and runner portfolio history | (peak_equity - current_equity) / peak_equity |
| sharpe | runner.runner.calculate_sharpe | mean(period_returns) / std(period_returns) * sqrt(252) |
| total_return | runner.runner.run_backtest | (final_equity / starting_equity) - 1 |
| trades | runner.execution.apply_trade | count of executed BUY/SELL state changes |
Controller metrics are computed locally from the project backtest. The attached data provenance identifies the external data source, symbol, row count, date range, download time, output CSV schema, and metric formulas used by downstream reports.
Controller Ranking
| Rank | Controller | Status | Return | Max DD | Sharpe | Trades | Score |
|---|---|---|---|---|---|---|---|
| 1 | flat | completed | 0.00% | 0.00% | 0.0000 | 0 | 0.0000 |
| 2 | metric | completed | 1.03% | 7.41% | 0.2642 | 38 | -6.3837 |
| 3 | hierarchical | completed | -8.00% | 9.88% | -1.1421 | 21 | -18.0088 |
| 4 | gated_hierarchical | completed | -8.82% | 11.06% | -2.0018 | 2 | -20.0834 |
Equity Curves
metric
flat
hierarchical
gated_hierarchical
Decision Analysis
| Controller | Return | Max DD | Sharpe | Trades | BUY | SELL | HOLD | Avg Conf | Avg Size |
|---|---|---|---|---|---|---|---|---|---|
| metric | 1.03% | 7.41% | 0.2642 | 38 | 44 | 56 | 0 | 0.5720 | 0.2200 |
| flat | 0.00% | 0.00% | 0.0000 | 0 | 0 | 0 | 100 | 0.0000 | 0.0000 |
| hierarchical | -8.00% | 9.88% | -1.1421 | 21 | 29 | 55 | 16 | 0.6245 | 0.2030 |
| gated_hierarchical | -8.82% | 11.06% | -2.0018 | 2 | 3 | 84 | 13 | 0.8435 | 0.0180 |
Top Decision Reasons
metric
- 56x Metric controller: close below SMA-3.
- 44x Metric controller: close above SMA-3.
flat
- 100x Flat controller stays out of market.
hierarchical
- 55x Hierarchical controller: close below SMA-5.
- 29x Hierarchical controller: short trend above medium trend.
- 16x Hierarchical controller: mixed signal.
gated_hierarchical
- 84x Gated hierarchical controller: drawdown gate triggered.
- 13x Gated hierarchical controller: gate did not approve risk-on action.
- 3x Gated hierarchical controller: trend allowed by risk gate.