PureBytes Links
Trading Reference Links
|
hi,
below your setup as I see it (see also example chart):
TimeFrameSet( inWeekly );
MA14_Weekly = MA( Close, 14 );
TimeFrameRestore();
TimeFrameSet( inDaily );
MA14_Daily = MA( Close, 14 );
TimeFrameRestore();
Buy=Cross(Close,MA14_Daily) AND Close > TimeFrameExpand( MA14_Weekly, inWeekly );
BuyPrice = Close;
SetChartOptions(0, chartShowDates);
Plot(C,"",colorWhite,64);
PlotShapes(IIf(Buy,shapeUpArrow,0),colorWhite, layer = 0, yposition = BuyPrice, offset = 0 );
Plot(TimeFrameExpand( MA14_Weekly, inWeekly ),"",colorWhite,1);
Plot(TimeFrameExpand( MA14_Daily, inDaily ),"",colorOrange,1);
----- Original Message -----
From: matrix10014
To: amibroker@xxxxxxxxxxxxxxx
Sent: Saturday, January 27, 2007 6:19 PM
Subject: [amibroker] Daily and weekly system
hi all,
I am attempting to code multiple time frame systems.As an example,i am
coding a system where you enter long on a daily moving av xover only
if the close is > than the weekly MA..Does this look right??
Has anyone found multiple time frame analysis useful??
wc = TimeFrameCompress( Close, inWeekly );
dailyma = MA( C, 14 );
weeklyma = MA( wc, 14 );
weeklyma = TimeFrameExpand( weeklyma, inWeekly );
Buy=Cross(Close,MA(Close,14) AND Close>weeklyma);
Sell=0;
positionsize=-2;
Thank you,
Allan
Content-Description: "AVG certification"
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.5.432 / Virus Database: 268.17.12/653 - Release Date: 1/26/2007 11:11 AM
|