[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[amibroker] 0 quotes



PureBytes Links

Trading Reference Links

Anybody out there have any comments on my questions from yesterday? 
I'm still trying to figure out if I'm messed up in my thinking aboout 
AFL and backtesting and timeframes and arrays ...

Dan

(Recopyng the original post here so it's not hashed up with carets 
and linefeeds).

--- In amibroker@xxxxxxxxxxxxxxx, "danielwardadams" 
<danielwardadams@xxxx> wrote:

I'm trying to backtest using intraday profit targets and trailing
stops. I can't get things to work right (very common problem with me
and AFL) and I think there are probably some AB basics I'm not
understanding right. So any help with the following questions would
be apppreciated.

(1) When backtesting, does the code get executed from top to bottom
for each available bar from the first bar to the last? Is this a 
valid way to think of things?

(2) If this is correct and I have 100,000 bars of 1 minute data and
my backtest periodicity is set to 1 minute, I think I'll have 100,000
complete passes through the AFL and will have 100,000 entries for
each piece of array data (open, close, etc). Is this correct?

(3) Is Barcount the number of bars to the current point in the data
(= point in time) or to the end of the data (100,000 in this case)? 
(I think it's the latter).

(4) At any point in time, will the Ref function will give me data
relative to where I'm at in the 1 minute data, e.g. will Ref(Open, -
60) give me the open from one hour ago?

(5) If I change intervals with Timeframeset, will the active Barcount
be adjusted accordingly (multiplied by 5 if I change from in1Minute
to in5Minute)?

(6) If I change from 1 to 5 minute data, will I be at the previous 5
minute multiple in time (i.e., is time "rounded down")?

(7) Within the 1 minute scenario, if I use Applystop to trail, will I
trail on a 1 minute basis? If I change to another interval (say
in5Minute) will I trail on that basis?

I know there has been a lot of discussion that Applystop won't trail
on intraday data and I've looked at some of the code to get around
this problem. But it seems if the above things are correct, it should
work the way I want.

Again, any help would be appreciated. If I'm way off base, maybe some
one could point me to some basic tutorial material on timeframes,
arrays, etc.

Dan



------------------------ Yahoo! Groups Sponsor ---------------------~-->
Buy Ink Cartridges or Refill Kits for your HP, Epson, Canon or Lexmark
Printer at MyInks.com.  Free s/h on orders $50 or more to the US & Canada.
http://www.c1tracking.com/l.asp?cid=5511
http://us.click.yahoo.com/mOAaAA/3exGAA/qnsNAA/GHeqlB/TM
---------------------------------------------------------------------~->

Send BUG REPORTS to bugs@xxxxxxxxxxxxx
Send SUGGESTIONS to suggest@xxxxxxxxxxxxx
-----------------------------------------
Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)
--------------------------------------------
Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
     http://groups.yahoo.com/group/amibroker/

<*> To unsubscribe from this group, send an email to:
     amibroker-unsubscribe@xxxxxxxxxxxxxxx

<*> Your use of Yahoo! Groups is subject to:
     http://docs.yahoo.com/info/terms/