Skip to content

BacktestingDataSource

interface cAlgo.API Since 5.3

DesktopCLICloud

Represents a backtesting data source.

Environment behaviour

CLI — not supported. Available to plugins only, and plugins cannot run in the CLI.

Cloud — not supported. Available to plugins only, and plugins cannot run in the cloud.

Definition

public interface BacktestingDataSource

Namespace: cAlgo.API · Group: DataSource

Examples

foreach (var dataSource in Backtesting.DataSources)
    Print("Data source {0}, only own custom time frames: {1}", dataSource.Name, dataSource.SupportOnlyOwnCustomTimeFrames);
for dataSource in api.Backtesting.DataSources:
    api.Print(f"Data source {dataSource.Name}, only own custom time frames: {dataSource.SupportOnlyOwnCustomTimeFrames}")

Methods

Name Description
ClearCacheDesktopCLICloudbool Clears cached price data of current data source if not being used.

Properties

Name Description
NameDesktopCLICloudstring Gets unique name of backtesting data source.
SupportOnlyOwnCustomTimeFramesDesktopCLICloudbool Gets / sets if current backtesting data source can be used only for owner plugin custom TimeFrames or for both owner plugin custom TimeFrames and built-in TimeFrames. If True current source will only appear if backtesting TimeFrame is owner plugin created custom TimeFrame.

See also