Interface StrategyStatisticsModel

Statistical data calculated from strategy events.

Provides metrics for strategy action tracking.

const stats = await Strategy.getData("BTCUSDT", "my-strategy");

console.log(`Total events: ${stats.totalEvents}`);
console.log(`Cancel scheduled: ${stats.cancelScheduledCount}`);
interface StrategyStatisticsModel {
    activateScheduledCount: number;
    averageBuyCount: number;
    breakevenCount: number;
    cancelScheduledCount: number;
    closePendingCount: number;
    eventList: StrategyEvent[];
    partialLossCount: number;
    partialProfitCount: number;
    totalEvents: number;
    trailingStopCount: number;
    trailingTakeCount: number;
}

Properties

activateScheduledCount: number

Count of activate-scheduled events

averageBuyCount: number

Count of average-buy (DCA) events

breakevenCount: number

Count of breakeven events

cancelScheduledCount: number

Count of cancel-scheduled events

closePendingCount: number

Count of close-pending events

eventList: StrategyEvent[]

Array of all strategy events with full details

partialLossCount: number

Count of partial-loss events

partialProfitCount: number

Count of partial-profit events

totalEvents: number

Total number of strategy events

trailingStopCount: number

Count of trailing-stop events

trailingTakeCount: number

Count of trailing-take events