BacktestingSettings.CommissionType
property · BacktestingSettings · cAlgo.API Since 5.10
DesktopCLICloud
Gets or sets the commission type that defines how the Commission property value is interpreted. It is ignored when ApplyCommissionAutomatically is set to true. The default value is SymbolCommissionType.UsdPerMillionUsdVolume.
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 SymbolCommissionType CommissionType {get; set;}
backtestingSettings.CommissionType: SymbolCommissionType
Returns SymbolCommissionType
Examples
var settings = new BacktestingSettings
{
Commission = 3.5,
CommissionType = SymbolCommissionType.UsdPerOneLot
};
Print("Commission type: {0}", settings.CommissionType);
settings = BacktestingSettings()
settings.Commission = 3.5
settings.CommissionType = SymbolCommissionType.UsdPerOneLot
api.Print(f"Commission type: {settings.CommissionType}")