I am trying to use VWAP as a crossover criteria for entering my strategy using NinjaScript Editor. I have OrderFlow+ and added this code to my script:
double VWAPValue = OrderFlowVWAP(VWAPResolution.Standard, TradingHours.String2TradingHours("CME US Index Futures RTH"), VWAPStandardDeviations.Three, 1, 2, 3).VWAP[0];
Print("The current VWAP with a standard resolution on CME US Index Futures RTH is " + VWAPValue.ToString());
if (market_open && (DailyProfit >= -1200))
//if (market_open)
{
if (Close[0] >= VWAPValue[0])
{
EnterLong(Convert.ToInt32(DefaultQuantity), "");
How can I just simply program it to enter whenever price reaches and crosses over VWAP?
Thank you,
Steve

Comment