I’m trying to get the price level on a specific date on a simple MT4 trendline (OBJ_TREND) defined by two coordinates (price =y, datetime=x). However, calculated prices (using a simple linear equation formula) are not correct (they come out 10s of pips away from the visual reading on the chart).
My understanding is that the problem is due to the fact that the date difference between T1 and T2 should be NET difference (excluding weekends and other virtual time gaps on the chart). Excel, for one example, has a NetWorkDays function that provides this exact net time difference.
I wonder if anyone has already figured out a solution for this. Or came up with a better/simpler solution to get the requested price levels on any trend line date?
My understanding is that the problem is due to the fact that the date difference between T1 and T2 should be NET difference (excluding weekends and other virtual time gaps on the chart). Excel, for one example, has a NetWorkDays function that provides this exact net time difference.
I wonder if anyone has already figured out a solution for this. Or came up with a better/simpler solution to get the requested price levels on any trend line date?