PerPeriodBaseTradeParameter
StockSharp.Algo.Statistics
Base class for calculating trade statistic parameters by aggregating trades over aligned time periods.
Inherits: BaseStatisticParameter<decimal>
Implements: ITradeStatisticParameter, IStatisticParameter, IPersistable, INotifyPropertyChanged, IDisposable
Constructors
PerPeriodBaseTradeParameter
protected PerPeriodBaseTradeParameter(StatisticParameterTypes type)
perPeriodBaseTradeParameter = PerPeriodBaseTradeParameter(type)
Base class for calculating trade statistic parameters by aggregating trades over aligned time periods.
- type
- Type
Methods
Add
public void Add(PnLInfo info)
perPeriodBaseTradeParameter.Add(info)
To add information about new trade to the parameter.
- info
- Information on new trade.
Align
protected abstract DateTime Align(DateTime date)
result = perPeriodBaseTradeParameter.Align(date)
Align the specified date for exact period start.
- date
- Trade date.
Returns: Aligned value.
Load
public override void Load(SettingsStorage storage)
perPeriodBaseTradeParameter.Load(storage)
To load the state of statistic parameter.
- storage
- Storage.
Reset
public override void Reset()
perPeriodBaseTradeParameter.Reset()
To reset the parameter value.
Save
public override void Save(SettingsStorage storage)
perPeriodBaseTradeParameter.Save(storage)
To save the state of statistic parameter.
- storage
- Storage.