Update MessengerService to reflect initial balance and net PnL in messages

This commit is contained in:
2025-11-15 13:44:50 +07:00
parent 6d661f459e
commit e814eb749c

View File

@@ -277,7 +277,7 @@ public class MessengerService : IMessengerService
$"⏱️ Timeframe: {config.Timeframe}\n" + $"⏱️ Timeframe: {config.Timeframe}\n" +
$"👤 Account: {config.AccountName}\n" + $"👤 Account: {config.AccountName}\n" +
$"💼 MM: 🛡️ SL: {mmSl}% | 🎯 TP: {mmTp}% | 📈 Lev: {mmLev}x\n" + $"💼 MM: 🛡️ SL: {mmSl}% | 🎯 TP: {mmTp}% | 📈 Lev: {mmLev}x\n" +
$"💰 Balance: {config.BotTradingBalance:C}\n" + $"💰 Balance: {backtest.InitialBalance:C} -> {config.BotTradingBalance:C} ({netPnl:C})\n" +
$"🧩 Indicators: {indicators}\n" + $"🧩 Indicators: {indicators}\n" +
$"📅 Period: {backtest.StartDate:yyyy-MM-dd} to {backtest.EndDate:yyyy-MM-dd}\n" + $"📅 Period: {backtest.StartDate:yyyy-MM-dd} to {backtest.EndDate:yyyy-MM-dd}\n" +
$"⏳ Cooldown: {config.CooldownPeriod} | 🔥 Max Loss Streak: {config.MaxLossStreak}\n" + $"⏳ Cooldown: {config.CooldownPeriod} | 🔥 Max Loss Streak: {config.MaxLossStreak}\n" +
@@ -288,7 +288,6 @@ public class MessengerService : IMessengerService
$"🔍 Score Analysis: {backtest.ScoreMessage}\n" + $"🔍 Score Analysis: {backtest.ScoreMessage}\n" +
$"🏆 Win Rate: {winRate:F1}%\n" + $"🏆 Win Rate: {winRate:F1}%\n" +
$"📊 Total Trades: {tradeCount}\n" + $"📊 Total Trades: {tradeCount}\n" +
$"💰 Net PnL: ${netPnl:F2}\n" +
$"📈 ROI: {growthPercentage:F1}%\n" + $"📈 ROI: {growthPercentage:F1}%\n" +
$"📉 Max Drawdown: ${maxDrawdown:N}\n" + $"📉 Max Drawdown: ${maxDrawdown:N}\n" +
$"📊 Sharpe Ratio: {sharpeRatio:F2}\n\n" + $"📊 Sharpe Ratio: {sharpeRatio:F2}\n\n" +