#!/bin/bash echo "==================================================================================================" echo "🏆 V9 MONEY LINE PARAMETER SWEEP RESULTS - 4,096 CONFIGURATIONS TESTED" echo "==================================================================================================" echo "" # Top 10 unique by performance echo "📊 TOP 10 CONFIGURATIONS BY P&L PER $1,000:" echo "" head -11 v9_exhaustive_4096_combined_sorted.csv | tail -10 | while IFS=',' read rank trades wr pnl pnl1k pf dd sr flip ma adx lp sp cool pos tp1 tp2 sl tp1c trail vol bars; do wr_pct=$(awk "BEGIN {printf \"%.1f\", $wr * 100}") echo "Rank #$rank: \$$pnl1k per \$1k | $trades trades | ${wr_pct}% WR | Total: \$$pnl" echo " ├─ Trend: flip=$flip ma_gap=$ma adx=$adx long_pos=$lp short_pos=$sp cooldown=$cool" echo " └─ Risk: TP1=${tp1}x TP2=${tp2}x SL=${sl}x Trail=${trail}x TP1_close=${tp1c}% vol=$vol" echo "" done echo "==================================================================================================" echo "📈 KEY FINDINGS:" echo "==================================================================================================" # Count unique pnl_per_1k values unique_pnl=$(tail -n +2 v9_exhaustive_4096_combined_sorted.csv | cut -d',' -f5 | sort -u | wc -l) total_configs=$(tail -n +2 v9_exhaustive_4096_combined_sorted.csv | wc -l) echo "Total Configurations Tested: $total_configs" echo "Unique P&L Results: $unique_pnl" echo "" # Best and worst best=$(head -2 v9_exhaustive_4096_combined_sorted.csv | tail -1 | cut -d',' -f5) worst=$(tail -1 v9_exhaustive_4096_combined_sorted.csv | cut -d',' -f5) echo "💰 Best Performance: \$$best per \$1,000" echo "💸 Worst Performance: \$$worst per \$1,000" echo "" # Parameter insensitivity check echo "🔍 PARAMETER SENSITIVITY ANALYSIS:" echo "" # Check flip_threshold variation in top 10 flip_04=$(head -11 v9_exhaustive_4096_combined_sorted.csv | tail -10 | cut -d',' -f9 | grep -c "0.4") flip_05=$(head -11 v9_exhaustive_4096_combined_sorted.csv | tail -10 | cut -d',' -f9 | grep -c "0.5") echo " flip_threshold in top 10: 0.4 appears $flip_04 times, 0.5 appears $flip_05 times" # Check ma_gap variation (should all be identical if insensitive) ma_gaps=$(head -11 v9_exhaustive_4096_combined_sorted.csv | tail -10 | cut -d',' -f10 | sort -u | wc -l) echo " ma_gap variations in top 10: $ma_gaps unique values (if >1, parameter matters)" # Check cooldown impact cool_1=$(head -11 v9_exhaustive_4096_combined_sorted.csv | tail -10 | cut -d',' -f14 | grep -c "^1$") cool_2=$(head -11 v9_exhaustive_4096_combined_sorted.csv | tail -10 | cut -d',' -f14 | grep -c "^2$") cool_4=$(head -11 v9_exhaustive_4096_combined_sorted.csv | tail -10 | cut -d',' -f14 | grep -c "^4$") echo " cooldown in top 10: 1=$cool_1, 2=$cool_2, 4=$cool_4 (clear winner if one dominates)" echo "" echo "=================================================================================================="