16 using System.Collections.Generic;
23 internal sealed
class TradesPerDayReportElement : ReportElement
46 public override string Render()
48 var liveOrders = _live?.Orders?.Values.ToList();
49 if (liveOrders ==
null)
51 liveOrders =
new List<Order>();
54 var orders = _backtest?.
Orders?.Values.Concat(liveOrders).OrderBy(x => x.Time);
65 var days = orders.Last().Time
66 .Subtract(orders.First().Time)
74 var tradesPerDay = orders.Count() / days;
79 return $
"{tradesPerDay:F0}";
82 return $
"{tradesPerDay:F1}";