I would like to make an indicator where one can select two bars on a chart. Then draw a line whose length and position are based on the time and price of the two bar points.
e.g. on chart select bar A low and bar B high - we have available time (or bar number) and Price for Bar A and Bar B. Then draw a line which is mid point between Bar A and Bar B in Time and Price to Bar B time and price.
How to access the mouse click data for price and time for the selected points and how to reference the bar time and open or close price to be able to calculate line start and end points and then plot the line?
thanks
Suraj

Comment