I am currently calculating the Spread in each relevant tick (where tick bar object = 2)
double Bid = GetCurrentBid(2);
double Ask = GetCurrentAsk(2);
double spread = Ask - Bid;
If i wanted to do a 100 Tick SMA of the spread, what would be the code structure, right now
I am using
double maSpread = SMA(GetCurrentAsk(2) - GetCurrentBid(2)) ,100)[0];
and getting the following error.
Argument '1': cannot convert from 'double' to 'NinjaTrader.Data.IDataSeries'
Thanks kindly in advance for any help,
Andrew

Comment