BruteForceOptimizer

StockSharp.Algo.Strategies.Optimization

The brute force optimizer of strategies.

Наследует: BaseOptimizer

Конструкторы

BruteForceOptimizer(IEnumerable<Security>, IEnumerable<Portfolio>, IStorageRegistry)

Initializes a new instance of the BruteForceOptimizer.

securities
Instruments, the operation will be performed with.
portfolios
Portfolios, the operation will be performed with.
storageRegistry
Market data storage.
BruteForceOptimizer(ISecurityProvider, IPortfolioProvider, IStorageRegistry)

Initializes a new instance of the BruteForceOptimizer.

securityProvider
The provider of information about instruments.
portfolioProvider
The portfolio to be used to register orders. If value is not given, the portfolio with default name Simulator will be created.
storageRegistry
Market data storage.
BruteForceOptimizer(ISecurityProvider, IPortfolioProvider, IExchangeInfoProvider, IStorageRegistry, StorageFormats, IMarketDataDrive)

Initializes a new instance of the BruteForceOptimizer.

securityProvider
The provider of information about instruments.
portfolioProvider
The portfolio to be used to register orders. If value is not given, the portfolio with default name Simulator will be created.
exchangeInfoProvider
Exchanges and trading boards provider.
storageRegistry
Market data storage.
storageFormat
The format of market data. Binary is used by default.
drive
The storage which is used by default. By default, DefaultDrive is used.

Методы

RunAsync(DateTime, DateTime, IEnumerable<ValueTuple<Strategy, IStrategyParam[]>>, CancellationToken) : IAsyncEnumerable<ValueTuple<Strategy, IStrategyParam[]>>

Run optimization and yield completed iterations as they finish.

startTime
Date in history for starting the paper trading.
stopTime
Date in history to stop the paper trading (date is included).
strategies
The strategies and parameters used for optimization.
cancellationToken
Cancellation token.

Возвращает: Async enumerable of completed (strategy, parameters) pairs.

RunAsync(DateTime, DateTime, Func<IPortfolioProvider, ValueTuple?<Strategy, IStrategyParam[]>>, CancellationToken) : IAsyncEnumerable<ValueTuple<Strategy, IStrategyParam[]>>

Run optimization and yield completed iterations as they finish.

startTime
Date in history for starting the paper trading.
stopTime
Date in history to stop the paper trading (date is included).
tryGetNext
Handler to try to get next strategy object.
cancellationToken
Cancellation token.

Возвращает: Async enumerable of completed (strategy, parameters) pairs.