PureBytes Links
Trading Reference Links
|
David,
You can just replace the line:
alltimehigh = LastValue(<FONT
color=#0000ff>Highest( High ) );
with
alltimehigh = LastValue(HHV(
High, 150 ) );
Best regards,Tomasz
Janeczko===============AmiBroker - the comprehensive share
manager.<FONT
size=2>http://www.amibroker.com
<BLOCKQUOTE
>
----- Original Message -----
<DIV
>From:
David
Holzgrefe
To: <A title=amibroker@xxxxxxxxxxxxx
href="">amibroker@xxxxxxxxxxxxxxx
Sent: Sunday, November 11, 20019:32
AM
Subject: [amibroker] new highs for xn
periods ?
Hi TJ sometime ago you shared this search with us for an all
time high ..
can it be modified to find a stock that is setting a new high
for a set period ?
lets say we want stocks that have set a new high for 150
days changing the range periods doesn't find stocks that are setting new
highs for xn periods
Thanks David
alltimehigh = LastValue<FONT
size=1>( Highest(
High ) );
alltimehighbar = ValueWhen<FONT
size=1>( High == alltimehigh, <FONT color=#0000ff
size=1>Cum(1<FONT
size=1>) );
alltimeyear = ValueWhen<FONT
size=1>( High == alltimehigh, <FONT color=#0000ff
size=1>Year() );
alltimemonth = ValueWhen<FONT
size=1>( High == alltimehigh, <FONT color=#0000ff
size=1>Month() );
alltimeday = ValueWhen<FONT
size=1>( High == alltimehigh, <FONT color=#0000ff
size=1>Day() );
"All time highest was " + <FONT color=#0000ff
size=1>WriteVal( alltimehigh );<FONT
color=#ff00ff size=1>
"on the " + <FONT color=#0000ff
size=1>WriteVal( alltimeyear, <FONT color=#ff00ff
size=1>1 ) + <FONT color=#ff00ff
size=1>"." + <FONT color=#0000ff
size=1>WriteVal( alltimemonth, <FONT color=#ff00ff
size=1>1 ) + <FONT color=#ff00ff
size=1>"." + <FONT color=#0000ff
size=1>WriteVal( alltimeday, <FONT color=#ff00ff
size=1>1 );
/* Draw also a buy arrow on highest day */
cond1 = High == alltimehigh ;Your
use of Yahoo! Groups is subject to the <A
href="">Yahoo! Terms of Service.
|