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

[amibroker] Re: Camarilla System- Help Needed



PureBytes Links

Trading Reference Links

This is a simple system actually:

1. Sell if the prices 'hit' R3 with Stop R4
2. Cover[if the prices did hit R3 first] and Buy when the prices hit S3 with stop S4.
3. Buy if prices cross R4 with stop R3
4. Short if prices breach S4 with stop S3.
5. Open positions [in case 3,4] should exit at the market in the last minute.

Any insights how to build it in Ami is appreciated.


--- In amibroker@xxxxxxxxxxxxxxx, "Soham" <sohamdas@xxx> wrote:
>
> I think it will be instructive if someone can send me a code for trading in intraday time frame. Perhaps from there I can have a go whhats lacking in my code and so on.
> 
> 
> --- In amibroker@xxxxxxxxxxxxxxx, "Soham" <sohamdas@> wrote:
> >
> > Thomas,
> > It still isn't working. Pressing the "Backtest" button gives out no result. The periodicity is 15minute in Settings window.
> > 
> > Soham
> > 
> > 
> > --- In amibroker@xxxxxxxxxxxxxxx, Thomas Ludwig <Thomas.Ludwig@> wrote:
> > >
> > > Soharn,
> > > 
> > > I haven't checked it but the Iif's should be removed:
> > > 
> > > Short=Cross(R3,C) OR Cross(S4,C);
> > > Cover=C<1.1*S3 OR C>0.97*R4;
> > > Buy=Cross(C,S3) OR Cross(C,R4);
> > > Sell=C>0.97*R3 OR C<1.1*S4;
> > > 
> > > Thomas
> > > 
> > > On 29.04.2009, 14:16:13 Soham wrote:
> > > > Hi All,
> > > >
> > > > This is my code based on the way I have read about Camarilla. I am
> > > > interested in finding out its performance.
> > > >
> > > > Yet, there is something wrong in this code. Whenever I try to backtest, no
> > > > trades are being taken.Help needed:
> > > >
> > > > The code is simple:
> > > >
> > > > //Intraday Trading System
> > > > R3=0;
> > > > R4=0;
> > > > S3=0;
> > > > S4=0;
> > > > YHigh = TimeFrameGetPrice("H", inDaily, -1);// yesterdays high
> > > > YLow = TimeFrameGetPrice("L", inDaily, -1);//low
> > > > YClose = TimeFrameGetPrice("C", inDaily, -1);//close
> > > > R4= YClose+ ((YHigh-Ylow)*1.1)/2;
> > > > R3= YClose+ ((YHigh-Ylow)*1.1)/4;
> > > > S3= YClose- ((YHigh-Ylow)*1.1)/4;
> > > > S4= YClose- ((YHigh-Ylow)*1.1)/2;
> > > > TimeFrameSet(in15Minute);
> > > > Short=IIf(Cross(R3,C) OR Cross(S4,C),1,0);
> > > > Cover=IIf(C<1.1*S3 OR C>0.97*R4,1,0);
> > > > Buy=IIf(Cross(C,S3) OR Cross(C,R4),1,0);
> > > > Sell=IIf(C>0.97*R3 OR C<1.1*S4,1,0);
> > > >
> > > > In plain words:
> > > > Wait for price (in intraday) to hit either R3 or S3, at that point,
> > > > initiate a short or a long respectively with stops as R4 or S4
> > > > respectively. If R4 or S4 is breached, go long or short, as it shows a
> > > > breakout from the previous day's volatility range.
> > > >
> > > > Help needed.
> > > >
> > > > Soham
> > > >
> > > >
> > > >
> > > > ------------------------------------
> > > >
> > > > **** IMPORTANT PLEASE READ ****
> > > > This group is for the discussion between users only.
> > > > This is *NOT* technical support channel.
> > > >
> > > > TO GET TECHNICAL SUPPORT send an e-mail directly to
> > > > SUPPORT {at} amibroker.com
> > > >
> > > > TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
> > > > http://www.amibroker.com/feedback/
> > > > (submissions sent via other channels won't be considered)
> > > >
> > > > For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
> > > > http://www.amibroker.com/devlog/
> > > >
> > > > Yahoo! Groups Links
> > > >
> > > >
> > > >
> > >
> >
>




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

**** IMPORTANT PLEASE READ ****
This group is for the discussion between users only.
This is *NOT* technical support channel.

TO GET TECHNICAL SUPPORT send an e-mail directly to 
SUPPORT {at} amibroker.com

TO SUBMIT SUGGESTIONS please use FEEDBACK CENTER at
http://www.amibroker.com/feedback/
(submissions sent via other channels won't be considered)

For NEW RELEASE ANNOUNCEMENTS and other news always check DEVLOG:
http://www.amibroker.com/devlog/

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/