d5400
this is what i think the most accurate solution .. fit1 / fit2 to adjust the slope before using arctan function to get angle in radians . .
. .
it gives accurate results on the chart, draw text to parallel it line (trend-line)
but i can not justify "why" ?
could you justify it? scientific, mathematical justification , that must convince me . .
look at the code output: text parallel the line (we take the slope of the line to set text degrees)
1) we take the slope of the line (y1-y0)/(x1-x0)
2) but it does not help, you name time axis and price axis !! no correlation!!
3) so i try to add factor fit of chart (width in candles, and height in price difference) using:
4) it helps a little! something better than nothing . .
4) later i try to add factor fit2 of the chart width and height but in pixel, the result is below... accurate, but mentally i can not justify!!
could anybody justify!! ?
factor: fit/fit2 ???? make things fine? why?
when you zoom in/out the chart, or compress/decompress, it reacts correspondingly, with accurate parallelism ??
when you attach it
move the trend line by mouse(you have 3 sec to do) , then check if text moving accordingly with the same angle . .
. .
this is what i think the most accurate solution .. fit1 / fit2 to adjust the slope before using arctan function to get angle in radians . .
. .
it gives accurate results on the chart, draw text to parallel it line (trend-line)
but i can not justify "why" ?
could you justify it? scientific, mathematical justification , that must convince me . .
look at the code output: text parallel the line (we take the slope of the line to set text degrees)
1) we take the slope of the line (y1-y0)/(x1-x0)
2) but it does not help, you name time axis and price axis !! no correlation!!
3) so i try to add factor fit of chart (width in candles, and height in price difference) using:
4) it helps a little! something better than nothing . .
4) later i try to add factor fit2 of the chart width and height but in pixel, the result is below... accurate, but mentally i can not justify!!
could anybody justify!! ?
factor: fit/fit2 ???? make things fine? why?
when you zoom in/out the chart, or compress/decompress, it reacts correspondingly, with accurate parallelism ??
when you attach it
move the trend line by mouse(you have 3 sec to do) , then check if text moving accordingly with the same angle . .
. .
Attached File(s)
sample_setting_inclined_texts_on_mt4_chart.ex4
11 KB
|
70 downloads
sample_setting_inclined_texts_on_mt4_chart.mq4
2 KB
|
79 downloads
Be yourself