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

Re: [amibroker] Code giving great results



PureBytes Links

Trading Reference Links

Thanks Steve and Graham,

Have followed your advice.

Nick




Graham wrote:
>
> Sell = Sellsig AND Ref(Intrade,-1);
>
> -- 
> Cheers
> Graham Kav
> AFL Writing Service
> http://www.aflwriting.com <http://www.aflwriting.com>
>
> 2008/7/24 Steve Dugas <sjdugas@xxxxxxxxxxx 
> <mailto:sjdugas%40comcast.net>>:
> > Hi - Off the top of my head I don't see how you are getting any Sell 
> signals
> > but I am probably overlooking something simple and so this seems 
> like a good
> > example of how looking at your actual arrays can help you to debug, 
> or in
> > this case, to *understand* how your code is acting on the arrays. 
> You can
> > plot the arrays but in this case I think explorer might be better ( 
> to avoid
> > overplotting since all arrays are 1's and 0's ). To see your arrays 
> for the
> > last year, try adding this to the end of your code, then in AA set N 
> last
> > quotes to 252 and run an exploration. You should be able to see, day 
> by day,
> > how the values in the earlier arrays lead to the values in the dependent
> > arrays...
> >
> > Steve
> >
> > AddColumn( BuySig, "BuySig", 1.0 );
> > AddColumn( SellSig, "SellSig", 1.0 );
> > AddColumn( InTrade, "InTrade", 1.0 );
> > AddColumn( Ref( InTrade, -1 ), "InTradeShifted", 1.0 );
> > AddColumn( Buy, "Buy", 1.0 );
> > AddColumn( Sell, "Sell", 1.0 );
> >
> > ----- Original Message -----
> > From: "nickrobn" <nickrobinson@xxxxxxxxxxxxxxx 
> <mailto:nickrobinson%40netspace.net.au>>
> > To: <amibroker@xxxxxxxxxxxxxxx <mailto:amibroker%40yahoogroups.com>>
> > Sent: Thursday, July 24, 2008 12:00 AM
> > Subject: [amibroker] Code giving great results
> >
> >
> >> Have following code:
> >>
> >>
> >> Buysig = buy conditions;
> >> Sellsig = Sell conditions;
> >>
> >> InTrade = Flip(Buysig,Sellsig);
> >>
> >> Buy = Buysig AND Ref(Intrade,-1)==0;
> >> Sell = Sellsig AND Ref(Intrade,-1)==0;
> >>
> >> I obtain much better results (higher profit, longer and fewer trades)
> >> with the inclusion of Ref(Intrade,-1)==0 in the formula. Can anyone
> >> tell me why?
> >>
> >> Thanks,
> >>
> >> Nick
> >>
> >>
>
>  


------------------------------------

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 NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

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/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/amibroker/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:amibroker-digest@xxxxxxxxxxxxxxx 
    mailto:amibroker-fullfeatured@xxxxxxxxxxxxxxx

<*> 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/