How to use an OHLC4 as DataSeries for the source param of an indicator ( like EMA )
Created at 19 Sep 2018, 03:34
How to use an OHLC4 as DataSeries for the source param of an indicator ( like EMA )
19 Sep 2018, 03:34
Idea here is pretty simple.
I would like to set the source series of my EMA to an OLHC4 value other than the standard close ( MarketSeries.Close to kinda MarketSeries.OHLC4 )
_exponentialMovingAverage = Indicators.ExponentialMovingAverage(MarketSeries.Close, PeriodEma);
I can't use also a custom indicator OHLC4 because the param type IndicatorsDataSeries does fit the DataSeries type
It must have a way to do this ?
Thanks
PanagiotisCharalampous
19 Sep 2018, 10:55
Hi thriscio,
You can set the source of an indicator to any source as long as it is a DataSeries type. IndicatorDataSeries type derives from DataSeries so you can use another indicator's result as an input to EMA.
Best Regards,
Panagiotis
@PanagiotisCharalampous