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

Re: [amibroker] EXploration help



PureBytes Links

Trading Reference Links

Hi iascool,

Sunday, October 23, 2005, 5:24:40 PM, you wrote:

i> I need a exploration for following condition

i> buy
i> 1- weighted MA 5 close > WMA6 open
i> 2- close > wma(20)
i> 3- ADX > 20 with +DI >-DI
i> 4- Kstoch(8,3)cross  above 40

i> sell
i> 1- weighted MA 5 close < WMA6 open
i> 2- close < wma(20)
i> 3- ADX > 20 with +DI <-DI
i> 4- Kstoch(8,3)cross  below 60

i> AB Code
i> //Momemtum Method

i> //Momemtum Method

i> Cond1= WMA(5,C)>WMA(O,6)

Notice that you have reversed the syntax above.  The first one is an
MA, periods, array; while the second one is an MA, array, periods.
They need to be the same, and the first one is incorrect.

Spaces are your friend, by the way.  They are certainly the friend of
people you ask for help.  ^_^

 AND ADX(14)>20 AND PDI(14)>MDI(14) AND Cross
i> (StochK(8,3),40) AND C>WMA(C,20);
i> Cond2= WMA(5,C)<WMA(O,6) AND ADX(14)>20 AND PDI(14)<MDI(14) AND Cross
i> (60,StochK(8,3)) AND C<WMA(C,20);
i> Buy=IIf(Cond1 ,1 ,0);
i> Sell=IIf(Cond2 ,1,0);
i> Filter =1;
i> AddColumn( Buy, "Bullish", 1 );
i> AddColumn( Sell, "Bearish", 1 );

i> I have coded for this as abive but there are no signals generated 
i> Can it be altered any way to genetrade signals . Advise appreciated

If it's only going to be an exploration, Buy and Sell statements may
just confuse you.

Also, Filter = 1 means that every item in the database will be
returned (i.e. nothing will be filtered).  Your filter statement
should eliminate anything not meeting your conditions.

Try rewriting your conditions, then try something like this:

AddColumn(IIf(Cond1,1,0), "Buy Signal (1)", format = 1.0 );

You could of course make it IIf(Cond1 AND Cond2,1,0), "Your text
here", etc.

Yuki



------------------------ Yahoo! Groups Sponsor --------------------~--> 
Try Online Currency Trading with GFT. Free 50K Demo. Trade 
24 Hours. Commission-Free. 
http://us.click.yahoo.com/RvFikB/9M2KAA/U1CZAA/GHeqlB/TM
--------------------------------------------------------------------~-> 

Please note that this group is for discussion between users only.

To get support from AmiBroker please send an e-mail directly to 
SUPPORT {at} amibroker.com

For other support material please check also:
http://www.amibroker.com/support.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/