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

Re: [amibroker] average of top ranked tickers in a given watchlist



PureBytes Links

Trading Reference Links

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Tue, 3 Aug 2004 22:35, Werner wrote:
> Good day,
>
> I would like to test a condition saying
>
> Stock X made a NEW High  WITHIN  the last 10 days.
>

nDays = 10;		// within the last ?? days
hDays = ????; 	// A new high for the ?? period
newHigh = Sum(HHVbars(H,hDays)==0, nDays)>0;
.
. rest of your afl
.
Buy = newHigh AND .....;


> "Within" meaning that the NEW HIGH could have acurred at any day
> within the last 10 days.
>

Sum() is one of the easliy overlooked functions, easy to understand what it 
does, but not so obvious what its useful for.  Here its counting the number 
of times HHVbars(...)==0 is True in ther period.  True is 1, False is 0;

> I know I have to use the HHV function, but could not formulate it.
>
> Thanks for any help.
>
> Werner

Your welcome,
	Nigel

- -- 
	Nigel Rowe
	rho@xxxxxxxxxxxxxxx


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQFBD4znBbmcM2pfckkRAuMDAJ9NUMd4Hwafho/MtQDOr9pcfG5rBQCfYY69
sUVhDkIqOVtb99ejl82CgWs=
=97YO
-----END PGP SIGNATURE-----



------------------------ Yahoo! Groups Sponsor --------------------~--> 
Yahoo! Domains - Claim yours for only $14.70
http://us.click.yahoo.com/Z1wmxD/DREIAA/yQLSAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Check AmiBroker web page at:
http://www.amibroker.com/

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/