I could not find any reference on this. history object seems to contain a lot more than what’s visible. but there must be a way to get the visible bars. is there?
thanks
Baris
I could not find any reference on this. history object seems to contain a lot more than what’s visible. but there must be a way to get the visible bars. is there?
thanks
Baris
All the bars are in history.data, which you can grab via the 3rd argument in the calculator method: map(data, i, history) - hope this helps!
Thank you for the response. I was not clear I think. Here is a screen capture. Tradovate code is putting out some debug statement of some sort in the console. It shows down there how many bars can fit into the screen and then how many are not being used on the right hand side. This is output when you make a zoom in or out in the chart screen. So I need actually barRange-rightOffset. and then use the history array to access the individual bars and do calculation I need. I couldn’t find any reference to these attributes or functions. It does not seem to be exposed.
thanks again
TOh interesting! I don’t think we’d be able to do that because you’d need access to the browser window document’s viewport to determine what’s in view. Our indicators run in a service worker so they are contained and can’t impact the trading app. This would be really useful, though.