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

RE: [amibroker] Need help with a code



PureBytes Links

Trading Reference Links

Here is a standard I have set up for myself to coincide with the tick values
for the ASX
It is set up for 2 ticks above the signal price and 2 ticks below sell
signal, but you could alter that fairly easily

IndBuy = valuewhen(buy, C); //base buy signal price value
IndSell = valuewhen(sell, C); //base sell signal price value
NumTick = 2;
BuyTick = iif(IndBuy<=0.098, 0.001, iif(IndBuy==0.099, (0.001+0.005)/2,
iif(IndBuy>=0.1 and IndBuy<=0.49, 0.005, iif(IndBuy==0.495, (0.005+0.01)/2,
0.01 ))));
SellTick = iif(IndSell<=0.1, 0.001, iif(IndSell==0.105, (0.001+0.005)/2,
iif(IndSell>=0.11 and IndSell<=0.5, 0.005, iif(IndSell==0.51,
(0.005+0.01)/2, 0.01 ))));
buyprice = IndBuy + NumTick * BuyTick ;
sellprice = IndSell - NumTick * BuyTick ;

Cheers,
Graham
http://groups.msn.com/ASXShareTrading
http://groups.msn.com/FMSAustralia

-----Original Message-----
From: netbull2000 [mailto:netbull2000@xxxxxxxxx] 
Sent: Monday, 9 June 2003 12:10 PM
To: amibroker@xxxxxxxxxxxxxxx
Subject: [amibroker] Need help with a code

I am trying to write a code that would allow to buy one tick above 
the high of the bar last crossed by the parabolic SAR. I am 
struggling... I am not getting what I want. Any help would be 
appreciated. 

TIA,
Wally



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 

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


------------------------ Yahoo! Groups Sponsor ---------------------~-->
Get A Free Psychic Reading! Your Online Answer To Life's Important Questions.
http://us.click.yahoo.com/Lj3uPC/Me7FAA/ySSFAA/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 

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