In this algo (enhanced by @ Adams and others), I am trying to find the daily opening price, current high price, Current low price and Yesterday's close price. Although my style so far (lines 82 - 85; the very bottom of the code) are logging some prices on live paper trade and backtest, but the prices seem to be off when I compare to the actual nasdaq, Nyse values or IBKR.

Does anyone know how to get the following:

  • Open price (price at 9:30AM ET time) on each trading day 
  • Current high and low prices (this algo runs every 1 minute, so these price will likely change every so often throughout the day)
  • Yesterday closing price for each stock

 

See attached algo for what I have attempted so far

I appreciate any suggestions

Author