to report the summary one time.>
Or even use the 'last issue' to trigger Filter.
< function incStaticVar(varName, value)
{
StaticVarSet(varName, StaticVarGet(varName) + value);
}
// for example:
incStaticVar("GapsUp2Pct", LastValue(Cum(CondGap)));>
If I'd done this more than once, I'd pro
On Wednesday 31 May 2006 08:33 pm, Phsst wrote:
> Thanks for your comments & critique.
Glad to help...
> Here is the sample 'one-pass' code for calculating statistics or
> ratios on an entire watchlist or other defined group of issues: (It
> does give a 'running' report with each issue that
with the StaticVarSet and Get notation combined with testing
Status("StockNum") == 0, which is obscure at best.>
Dan,
I got the above OK. And yes, after years of working with AB, my brain
got tangled up on the arrays when I tried to combine them with scalers.
Thank you for the 'eye opening'
On Wednesday 31 May 2006 12:35 pm, Phsst wrote:
> I very much like the StaticVariable idea, but I tried the following
> code and AFL does not like my version of "somecalculation"...
>
> if( Status("StockNum") == 0 ) StaticVarSet("GapsUp2Pct", 0 );
> CondGap = O >= Ref(H, -1) * 1.02; // Opening
> How about AddToComposite
I use AddToComposite for more complex things, but for simple
statistical stuff, I'd prefer a simple single pass explore against a
list where I can accumulate some counts and then calculate percentages
or ratios or whatever against the entire list rather than si
arSet("yourvariable", somecalculation +
StaticVarGet("yourvariable") );
Best regards,Tomasz Janeczkoamibroker.com
- Original Message -
From:
Phsst
To: amibroker@yahoogroups.com
Sent: Wednesday, May 31, 2006 3:37
AM
Subject: [amibroker] Re: Help *countin
>>For example obtain a count of the number of engulfing patterns found
for that day over all stocks in my list:>>
Spend a little time looking at this example of gathering stats for an
entire watchlist in an Explore and you should be able to adapt it to
your needs. (Quite some time ago I tried t
Should be something like:
IIf(Low < Ref(Low,-1) AND High > Ref(High,-1), AddToComposite( 1, "Name
of Candle Pattern", "C"),0);
Regards,
Duke Jones, CMT
voyager_3k wrote:
> Did look at CUM(), but that did not give me what I wanted. I think
> AddToComposite(...) seems to be one possibilit
Did look at CUM(), but that did not give me what I wanted. I think
AddToComposite(...) seems to be one possibility.
TY ... AP
--- In amibroker@yahoogroups.com, "wavemechanic" <[EMAIL PROTECTED]> wrote:
>
> Take a look at Cum()
> - Original Message -
> From: voyager_3k
> To: ami