import { DataFrame } from 'danfojs-node'; import { Strategy as BaseStrategy } from './strategy'; import { Broker } from './broker'; import { Stats } from './stats'; import { HistoricalData, BacktestOptions } from './interfaces'; import { StatsIndex } from './enums'; export declare class Backtest { private readonly Strategy; private readonly options?; private _data; private _stats?; constructor(data: HistoricalData, Strategy: new (data: DataFrame, broker: Broker) => BaseStrategy, options?: BacktestOptions | undefined); get data(): DataFrame; get stats(): Stats | undefined; /** * Run the backtest for the strategy. */ run(options?: { params?: Record; }): Promise; /** * Optimize strategy parameters. */ optimize(options: { params: Record; max?: StatsIndex; }): Promise; /** * Print the results of the backtest run. */ print(): this; /** * Plot the equity curve of the backtest run. */ plot(): this; private runner; }