You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Over the weekend, the ActualPrice function returns the current date as opposed to the date the instrument last traded. For example, calling the ActualPrice function on a Saturday will return Saturday's date instead of the last date (the previous Friday usually) when the instrument traded.
The fix is straightforward and included below. Don't bother calling as.POSIXct when it isn't used later anyway.
Replace the line below...
DateTime <- as.POSIXct(substr(InstPrecjson[[1]]$time,12,19), format = "%H:%M:%S")
... with this line.
DateTime <- substr(InstPrecjson[[1]]$time,1,19)
The text was updated successfully, but these errors were encountered:
Over the weekend, the ActualPrice function returns the current date as opposed to the date the instrument last traded. For example, calling the ActualPrice function on a Saturday will return Saturday's date instead of the last date (the previous Friday usually) when the instrument traded.
The fix is straightforward and included below. Don't bother calling as.POSIXct when it isn't used later anyway.
Replace the line below...
DateTime <- as.POSIXct(substr(InstPrecjson[[1]]$time,12,19), format = "%H:%M:%S")
... with this line.
DateTime <- substr(InstPrecjson[[1]]$time,1,19)
The text was updated successfully, but these errors were encountered: