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

RE: [amibroker] Code help: Point & Figure Buy Signals



PureBytes Links

Trading Reference Links

It should be there, possibly different name like PFClose.afl (cannot
remember exact name I had it in when I uploaded it.)



Cheers,
Graham
http://groups.msn.com/ASXShareTrading
http://groups.msn.com/FMSAustralia
-----Original Message-----
From: Gary A. Serkhoshian [mailto:serkhoshian777@xxxxxxxxx] 
Sent: Sunday, 14 September 2003 1:46 PM
To: amibroker@xxxxxxxxxxxxxxx
Subject: RE: [amibroker] Code help: Point & Figure Buy Signals


Graham,

I couldn't find the file in the AFL Library, d Ind PF Close.afl, which you
referenced in the code attached.

Regards,
Gary


Graham <gkavanagh@xxxxxxxxxxxxx> wrote:
Yes, I did one a while ago on BPI, and also have used signals from P&F
charts in backtesting various means
Here is a search formula I did with the P&F code in another file, this can
be found in AFL library
//P&F Chart Signals based on Closing prices
// 07 Jan 2003
//Reverse is 3 boxes.
//Graham Kavanagh 

#include "C:\Program Files\AmiBroker\My AFL Dollars\d Ind PF Close.afl";

LastHigh = IIf(C>O,Ref(H,-2),Ref(H,-1));

Breakout = C>O AND H>Ref(H,-2);
EqualHigh = C>O AND H==Ref(H,-2);
NearHighUp = C>O AND H>=Ref(H,-2)-3*Box AND H<Ref(H,-2);
NearHighDown = C<O AND L>=Ref(H,-1)-3*Box;
TurnUp = C>O AND H<Ref(H,-2)-3*Box;

EntryPrice = LastHigh+Box;
ExitPrice = IIf(C<O,Ref(H,-1)-5*Box,H-5*Box);

Retraced = C<O AND L<=Ref(H,-1)-4*Box AND L>=Ref(L,-2);
Falling = C<O AND L<Ref(L,-2);

Filter = EqualHigh OR BreakOut OR NearHighUp OR NearHighDown OR Retraced OR
Falling OR TurnUp;
AddTextColumn( SectorID(1), "Sector" );
AddTextColumn(WriteIf(C>O,"Rise","Fall"),"U/D",1.0);
AddTextColumn("Box = "+WriteVal(Box,1.1),"box");
AddTextColumn("LastH= "+WriteVal(LastHigh,1.1),"LastH");
AddTextColumn("Price= "+WriteVal(IIf(C>O,H,L),1.1),"NowH");
AddTextColumn(
WriteIf(EqualHigh,"EqulH",
WriteIf(BreakOut,"BkOut ",
WriteIf(NearHighUp,"NearH ",
WriteIf(NearHighDown,"NearHd ",
WriteIf(Retraced,"Rtrcd ",
WriteIf(Falling,"BkDwn",
WriteIf(TurnUp,"BmTrn",
""))))))),"descrptn" );

AddTextColumn(
WriteIf(EqualHigh OR NearHighUp OR TurnUp,"BuySig=
"+WriteVal(EntryPrice,1.1),
WriteIf(BreakOut,"BuyWas= "+WriteVal(EntryPrice,1.1),
WriteIf(Falling,"SellWas= "+WriteVal(ExitPrice,1.1),
WriteIf(Retraced,"SellSig= "+WriteVal(ExitPrice,1.1),
WriteIf(NearHighDown, "SSg=" +WriteVal(ExitPrice,1.1)+" or
BSg="+WriteVal(EntryPrice,1.1),
""))))),"prices signal");

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


-----Original Message-----
From: serkhoshian777 [mailto:serkhoshian777@xxxxxxxxx] 
Sent: Sunday, 14 September 2003 12:38 PM
To: amibroker@xxxxxxxxxxxxxxx
Subject: [amibroker] Code help: Point & Figure Buy Signals


Hello all,

Has anyone figured out how to code a Point and Figure buy signal as 
defined by stockcharts.com

See below for their definition, and thanks in advance for any help.

Regards,
Gary



Point and Figure Buy Signal

P&F Buy and Sell signals are very simple patterns that should be 
confirmed before placing a trade. The P&F Buy signal is used when 
calculating the various Bullish Percent indices.

P & F Buy 



O
O  X  <-- buy signal
O  XO
OX XO
OXOXO
OXOXO
OXO O <-- not a sell signal yet
O


When the last signal on the chart was a buy signal, that is, the 
last breakout was a column of Xs going higher than the previous 
column of Xs and no sell signal (no column of Os breaking below the 
previous column of Os) has happened since the buy signal.



------------------------ 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/l.m7sD/LIdGAA/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 

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



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 the Yahoo! Terms of Service. 



Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software 
Yahoo! Groups Sponsor
ADVERTISEMENT




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 the Yahoo! Terms of Service. 


------------------------ 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/l.m7sD/LIdGAA/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 

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