fxshrat
Private Group
Posts: 566
Received Likes: 211
|
Post by fxshrat on Apr 1, 2016 18:54:09 GMT
They do correspond to correct start and end of bar! Just plot a line of higher TF close. A 15 min bar starts from i.e. 14:30:00 to 14:44:59 I'm out of this thread.
|
|
|
Post by bobpit on Apr 1, 2016 19:47:41 GMT
Hi, I was able to create that graph too.
Now I need to figure out why we need to hack the output of timeframe functions to align the bars to rounded times.
Thank you for the help and the code.
|
|
pan
Rookie
Posts: 27
Received Likes: 2
|
Post by pan on Apr 1, 2016 21:34:44 GMT
hi .. i was reading this post and i just by curiosity copy/paste the Reply #8
Bob look below what i am reading in the interpritation.. looking 1 min database " times are round " i think maybe you have to look the preferences setings/intraday START TIME of interval is it checked ?
|
|
|
Post by bobpit on Apr 1, 2016 21:42:55 GMT
hi .. i was reading this post and i just by curiosity copy/paste the Reply #8 Bob look below what i am reading in the interpritation.. looking 1 min database " times are round " i think maybe you have to look the preferences setings/intraday START TIME of interval is it checked ? Hello pan The code at post #8 is specially modified to change the date/time. It is for aesthetic reasons (I believe) and I also get round numbers. Yes, the START TIME of Interval is checked in my settings. You need to test the code I wrote on my first post. For some reason that I still cannot figure out, the times are not rounded.
|
|
pan
Rookie
Posts: 27
Received Likes: 2
|
Post by pan on Apr 1, 2016 22:28:32 GMT
Would you have any idea why this is happening? When I use the chart combo box to select 15min, I get nice round numbers: 15:45, 16:00, 16:15 etc. Why can't I get the same through AFL? Ok i read more carefully this time For example from time 12:45 until 1:00 oclock In 15 min TF we have 15 bars. So the very first bar Start at 12:45 , and then we have 14 more bars to count down, the last bar (15th) has time 12:59. The first bar (time rounded) + 14 = 15 bars Hmmm… that’s why FX he said uses DateTimeAdd() function to output the way you want.
|
|
|
Post by bobpit on Apr 2, 2016 7:40:24 GMT
Hmmm… that’s why FX he said uses DateTimeAdd() function to output the way you want. Yes, FX was quick and fixed how things LOOK on the chart. However it still troubles me why the TimeFrame functions do not produce rounded times, as specified by the settings. Pan, do you get similar output from my code? Do you get the times shifted by only 1 minute? Maybe more? Could it be related to the data? Nobody else noticed this in the past?
|
|
fxshrat
Private Group
Posts: 566
Received Likes: 211
|
Post by fxshrat on Apr 3, 2016 9:57:38 GMT
Hmmm… that’s why FX he said uses DateTimeAdd() function to output the way you want. Yes, FX was quick and fixed how things LOOK on the chart. However it still troubles me why the TimeFrame functions do not produce rounded times, as specified by the settings. Pan, do you get similar output from my code? Do you get the times shifted by only 1 minute? Maybe more? Could it be related to the data? Nobody else noticed this in the past? If you choose Start Time of Interval then Datetime of higher time frame will show start time of last lower time frame's bar within higher time frame bar. So for example if LTF: 5min and HTF: 15min then on LTF it will show i.e. 14:40:00 for 15min bar starting from 14:30:00. If you choose End time of Interval then it will show 14:44:59 for 15min bar starting from 14:30:00 If Start Time of Interval is chosen and LTF: 1min and HTF: 15min then on LTF it will show i.e. 14:44:00 for 15min bar starting from 14:30:00. If you choose End time of Interval then it will show 14:44:59 for 15min bar starting from 14:30:00. So simply set to End time of Interval.
|
|
|
Post by bobpit on Apr 3, 2016 19:23:56 GMT
So simply set to End time of Interval. I am very reluctant to change such a basic setting in the database, the recommended default that I have always used. However I did test it on a chart. ALL bars (even in lower TimeFrames) changed to xx:xx:59. I am not sure I want this.
|
|
fxshrat
Private Group
Posts: 566
Received Likes: 211
|
Post by fxshrat on Apr 3, 2016 19:28:22 GMT
To be honest, I don't care what you want. I tell you how the things are designed.
Go to AB support then. I'm not the developer of the software.
|
|
fxshrat
Private Group
Posts: 566
Received Likes: 211
|
Post by fxshrat on Apr 3, 2016 23:17:58 GMT
To be honest, I don't care what you want. I tell you how the things are designed. Go to AB support then. I'm not the developer of the software. The first sentence possibly does sound harsher than it was meant. Thing is personally I really don't care because to me it is not a problem. Also I don't know what you want other users to do about it. It is the way it works for HTF datetime output on lower TF. If you have a problem with it then only way is to go to AB technical support.
|
|