Australian (ASX) Stock Market Forum

Amibroker FAQ

Has anyone managed to successfully import minutely FX data into amibroker and get it to correctly compress it into daily bars?
I am having alot of problems with this, and it seems to be a common issue that was discussed on the yahoo message boards (last thread was in 2010). It seems to be related to amibroker's inability to correctly handle DST or inability to correctly define weekends.
I have tried to follow this guide but the compressed data is still incorrect.

If anyone knows of an alternative trading program then I would like to hear it.

Cheers

Not clear why you are having a problem. What have you tried so far (post that part of your code).
 
Hello -

First, thanks to the Amibroker and Aussie Stock Forums community for the great support. I have come a long way with Amibroker in a short amount of time because of the community.

I cannot seem to code a sell signal for a long term trend following system I am working on. The entry signal is a new all time closing high, which is working fine. However, one of two sell signals I have is not working.

//Buy when new all-time high close is made
Buy = C > Ref(HHV(C,99999999),-1);

Sell signal 1: a wide ATR based chandelier trailing stop (I have this already coded, using 10*50 day atr, and is working correctly)

I am having a difficult time implementing a second sell rule. I would like to sell when the high of the current bar is lower than the low of the bar of the original buy signal.

For example:

Buy signal bar: H 102, L 98, C 100 (a new all time closing high is made, therefore a buy signal is taken)

Next bar: H 99, L 97, C 98 (this is still a hold since the H is greater than the Low of 98 of the Buy signal bar

Third Bar: H 97, L 94, C 95 (this is a sell signal since the H of the day is lower than the low of the Buy signal bar)


The goal is to have either the long term ATR trailing stop or the new second sell rule based on a lower high since the last purchase be the exit options.

I believe the new sell rule would use the Ref or LastValue functions however I cannot see to get them to work.

Any help would be appreciated and thank you for the help,

Bill
 
His problem is a heavily outdated version from an unofficial website.

I don't see where Waterbottle gave his version so I don't know what version he is using or if it is illegal. If it is a very old version then he can update one way or another otherwise it is a code problem. At this point we don't know which.
 
I don't see where Waterbottle gave his version so I don't know what version he is using or if it is illegal. If it is a very old version then he can update one way or another otherwise it is a code problem. At this point we don't know which.

He doesn't have to give the version. Just by looking at his pictures it is clearly recognizable (by AB insiders) that it is a version being minimum 5.30 or prior. So it's a very, very old one. I won't tell you how to recognize it. It is one significant feature. Then he is clearly new to the software so it is very easy to combine 1 + 1 = 2 to come to conclusion where the setup+stuff is coming from.
 
I don't see where Waterbottle gave his version so I don't know what version he is using or if it is illegal. If it is a very old version then he can update one way or another otherwise it is a code problem. At this point we don't know which.

Hi colion,

I have in fact downloaded the latest version of amibroker to see if there was any change. But there isn't.
I have sent them an email and we are working on the issue.
It may be a settings problem, but I honestly doubt it as I have followed every guide available. This seems to have been an issue with other people too:
  1. https://www.mail-archive.com/amibroker@yahoogroups.com/msg50902.html
  2. https://www.mail-archive.com/amibroker@yahoogroups.com/msg12787.html
  3. https://www.aussiestockforums.com/forums/showthread.php?t=1679&p=661713&viewfull=1#post661713

One suggested solution (in the first thread linked) is to export data from amibroker with the DST timeshift applied and then re-import it without a timeshift.


He doesn't have to give the version. Just by looking at his pictures it is clearly recognizable (by AB insiders) that it is a version being minimum 5.30 or prior. So it's a very, very old one. I won't tell you how to recognize it. It is one significant feature. Then he is clearly new to the software so it is very easy to combine 1 + 1 = 2 to come to conclusion where the setup+stuff is coming from.

No, you are just wrong.

I have been using amibroker for a while now, but I was never consistent with using AFL hence my poor understanding of it. In fact, you can find the older version of their software on their devlog.
I also have Windows XP running on another computer. Would you like to accuse me of pirating that too?
 
No, you are just wrong.

I have been using amibroker for a while now, but I was never consistent with using AFL hence my poor understanding of it. In fact, you can find the older version of their software on their devlog.
I also have Windows XP running on another computer. Would you like to accuse me of pirating that too?

No, I'm not wrong. Your pictures clearly show a version equal or lower 5.30.
And import or connecting to some real time source has got nothing to do with AFL.
Using data in AB the first time after 5...6...7 years?

As for devlog you can download only most recent version there too!
Of course the devolg shows infos of developments of previous years, it is a log.
But also if you click old links of i.e. 5.30 from many years ago it will download most recent development version only. http://www.amibroker.com/devlog/2010/04/20/amibroker-5-30-official-release/
or 5.20 from 2008 http://www.amibroker.com/devlog/2008/11/26/amibroker-520-official-release/
Well ...
 
No, I'm not wrong. Your pictures clearly show a version equal or lower 5.30.
And import or connecting to some real time source has got nothing to do with AFL.
Using data in AB the first time after 5...6...7 years?

As for devlog you can download only most recent version there too!
Of course the devolg shows infos of developments of previous years, it is a log.
But also if you click old links of i.e. 5.30 from many years ago it will download most recent development version only. http://www.amibroker.com/devlog/2010/04/20/amibroker-5-30-official-release/
or 5.20 from 2008 http://www.amibroker.com/devlog/2008/11/26/amibroker-520-official-release/
Well ...

http://www.amibroker.com/devlog/2010/07/20/amibroker-5-30-3-64-bit-version-maintenance-update/
 
LOL you are hilarious! I don't know what I've done to earn this hostility.

Do you think it is possible that people have more than one computer in their home? :eek:

Hostility? I'm just curious. So you downloaded 5.30 in 2010 and have your own license for that one but haven't touched the whole thing for 5 years?
 
Hostility? I'm just curious. So you downloaded 5.30 in 2010 and have your own license for that one but haven't touched the whole thing for 5 years?

Nope, no need for license. Just trial version as I don't use it that often. Just have to backfill data every time you want to use.
 
Nope, no need for license. Just trial version as I don't use it that often. Just have to backfill data every time you want to use.

There is no 5-years trial version but just a 30-days one. And if you "trial 5 years" then it still makes no sense to use an outdated one anyway. Well, except for the reasons previously mentioned .. having some medicine for that one only.

Since you don't use it often anyway no one should waste more time with a cheap one, neither AB support nor users here.
 
There is no 5-years trial version but just a 30-days one. And if you "trial 5 years" then it still makes no sense to use an outdated one anyway. Well, except for the reasons previously mentioned .. having some medicine for that one only.

Since you don't use it often anyway no one should waste more time with a cheap one, neither AB support nor users here.

I didn't really have any need to upgrade so there was no point. Besides, I could do everything I wanted with the trial version and I could usually find help from their KB, yahoo message boards or forums.
I never forced anyone to assist me
 
I didn't really have any need to upgrade so there was no point. Besides, I could do everything I wanted with the trial version and I could usually find help from their KB, yahoo message boards or forums.
I never forced anyone to assist me

Again, there is no multi years trial period.

You may install and use an unlimited number of copies of the Shareware unregistered version for a trial period of 30 days for evaluation purpose only.
 
Method for importing Forex data from Interactive Brokers


I have had some problems importing FX data from IB. The problem encountered was that the data as presented in AmiBroker looked nothing like that shown in IB's TWS. Following the guides in AmiBroker's KB were helpful but still did not result in the correct data.
AmiBroker support were gracious enough to inform me that this discrepancy was due to an inability to vary time-shift between months. This is important as daylight savings occurs at different times and in different directions between the southern and northern hemisphere. This results in a time discrepancy of 1-2 hours which varies throughout the trading year and that cannot be accounted for. Although this may not be a big issue for those who just use weekly or monthly data, it becomes problematic if your focus is on hourly or even daily data. Below is an illustration which hopefully demonstrates what I am saying:

example.png

As you can see, the time difference varies through out the year, and as AmiBroker cannot accommodate for a variable time difference, you get data bars which have been incorrectly shifted.

Solution
The solution is to backfill the data in the same timezone as that is provided by IB. This will mean you will get the data in US Eastern time, not in Australian time, but it will at least provide you with the correct data.
Note: Once you change your settings back to AEDST, the data will probably get over written or changed to match AEDST. This solution will only give you the correct historical FX data matched to exchange date & time


Step 1: Change your system time to US Eastern

1.png
This can be found in the bottom right hand corner of your screen. Just click on the clock and select 'Change date and time settings'.

Step 2: Change TWS to US Eastern time
2.png
Select the 'Show all fields' hyperlink in the bottom left hand corner of the dialog box.
3.png
Select the 'Time Zone' button
4.png
Scroll through to the bottom until you find 'US/Eastern'. Select this and hit the 'OK' button. Log in as usual.
 
Sorry for big post - ASF doesn't allow more than 5 images

Step 3: Set up AmiBroker's database
6.png
7.png
First, make sure that your preferences are correct. You need to make sure that you select the 'START time of interval' in the intraday tab.
8.png
9.png
Then setup the database. The 'Number of bars:' value doesn't have to be the same as mine. The 'Trading hours' need to be the same, and so does 'First day of the week'. The reason for this is that this is the FX trading timetable in US Eastern time as shown below.
10.png

Once that is all done you can just hit the backfill current selection on your IB plugin. That should give you data as presented in IB's TWS.
REMEMBER TO CHANGE YOUR SYSTEM TIME AND TWS TIME BACK TO NORMAL after backfilling. Also, you need to shutdown your IB plugin afterwards, otherwise the backfill process will just overwrite everything you did.
 
Top