![]() |
ماشاء الله تبارك الله ماشاء الله لاقوة الا بالله , اللهم اني اسالك الهدى
والتقى والعفاف والغنى
| |
|
|
|
|
|
|
|||||||
|
|
|
|
|
#1 | |
|
[ ![]() البولينجر ![]() المعادلة الخاصة بالبولينجر كود:
|
|
|
|
|
|
|
#2 | |
|
بارك الله فيك
|
|
|
|
|
|
|
#3 | |
|
MFI ![]() معادلة mfi كود:
{ The trading system below buys a position whenever MFI crosses below 25.
It sells all open positions as soon as MFI crosses above 75.
The ChartScript also colors MFI bars red and green to show oversold/overbought levels. }
var MFIPANE, BAR, P: integer;
MFIPane := CreatePane( 100, true, true );
PlotSeries( MFISeries( 14 ), MFIPane, #Black, #Thick );
DrawLabel( 'MFI( 14 )', MFIPane );
for Bar := 14 to BarCount - 1 do
begin
if CrossUnderValue( Bar, MFISeries( 14 ), 25) then
BuyAtMarket( Bar + 1, '');
if CrossOverValue( Bar, MFISeries( 14 ), 75) then
for P := 0 to PositionCount - 1 do
if PositionActive( P ) then
SellAtMarket( Bar + 1, P, 'MFI' );
if MFI( Bar, 14 ) < 25 then
SetSeriesBarColor( Bar, MFISeries( 14 ), #Red );
if MFI( Bar, 14 ) > 75 then
SetSeriesBarColor( Bar, MFISeries( 14 ), #Green );
end;
DrawHorzLine( 80,mfiPane, #red, #thin );
DrawHorzLine( 50,mfiPane, #Olive, #dotted );
DrawHorzLine( 20,mfiPane, #green, #thin );
|
|
|
|
|
|
|
#4 | |
|
MACD ![]() معادلة الماكد كود:
var PPOPANE, MACDPane, WeeklyPPOPane, MyMACD, MYPPO, MYPPO2, WeeklyPPO, PlotWeeklyPPO, BAR, MYPPOHISTO, MyPPOHisto2, WeeklyPPOHisto, PlotWeeklyPPOHisto, WeeklySignalLine, PlotWeeklySignalLine, MYMACDHISTO: Integer;
var RealOldWeekSignal, OldWeekSignal, CurrentWeekSignal: float ;
// --------------------------------------------------------------------------------------- //
{ Create a new chart pane to hold our MACD indicator }
MACDPane := CreatePane( 100, TRUE, TRUE );
{Develop the 12,26 MACD Oscillator}
MyMACD := CreateSeries();
for Bar := 26 to BarCount () - 1 do
SetSeriesValue ( Bar, MyMACD, EMA( Bar, #close, 12) - EMA( Bar, #close,26 ) );
{ Set the series for the MACD Histogram }
MyMACDHisto := CreateSeries();
for Bar := 26 to BarCount () - 1 do
SetSeriesValue ( Bar, MyMACDHisto, ((EMA( Bar, #close, 12) - EMA( Bar, #close,26 ))) - EMA(Bar, MyMACD, 9 )) ;
// --------------------------------------------------------------------------------------- //
{Develop the 12,26 Percentage Price Oscillator}
MyPPO := CreateSeries();
for Bar := 26 to BarCount () - 1 do
SetSeriesValue ( Bar, MyPPO, ( EMA( Bar, #close, 12) - EMA( Bar, #close, 26 )) / EMA( Bar, #close, 12 ) );
{ Set the series for the PPO Histogram }
MyPPOHisto := CreateSeries();
for Bar := 26 to BarCount () - 1 do
SetSeriesValue ( Bar, MyPPOHisto, (( EMA( Bar, #close, 12) - EMA( Bar, #close, 26 )) / EMA( Bar, #close, 12 )) - EMA(Bar, MYPPO, 9 )) ;
//----------------------------------------------------------------------------------------------------------//
{Plot the 12,26 MACD}
PlotSeries( MyMACD, MACDPane, #red, #Thin ) ;
{Plot a 9 day MACD signal line}
PlotSeries( EMASeries( MyMACD, 9 ), MACDPane, #blue, #Thin ) ;
{Plot the MACD Histogram}
PlotSeries( MyMACDHisto,MACDPane, 222, #ThickHist) ;
DrawText( 'MACD( 12, 26, 9 )',MACDPane, 4, 4, #navy, 10 );
|
|
|
|
|
|
|
#5 | |
|
الارون ![]() كود:
var BAR,chartpane: integer;
for Bar := 20 to BarCount - 1 do
begin
if PriceClose(bar) > 5000 then setpositionsize(priceclose(bar)*1.1);
if LastPositionActive then
begin
if PositionLong( LastPosition ) then
{ Long Position Exit Rules }
begin
if (Aroondown(bar,#close,7) > 99) then
SellAtMarket( Bar+1, LastPosition, '' );
end
else
{ Short Position Exit Rules }
begin
if (Aroonup(bar,#close,7) > 99) then
CoverAtMarket( Bar+1, LastPosition, '' );
end;
end
else
begin
{ Long Position Entry Rules }
if (Aroonup(bar,#close,14) = 100) and (Aroondown(bar,#close,14) < 40) then
BuyAtMarket( Bar+1,'')
{ Short Position Entry Rules }
else if (Aroonup(bar,#close,14) < 40) and (Aroondown(bar,#close,14) = 100) then
ShortAtMarket( Bar+1,'');
end;
end;
chartPane := CreatePane( 75, true, true );
PlotSeries( AroonUpSeries( #Close,14 ), chartpane, 009, #Thin );
PlotSeries( AroonDownSeries( #Close,14 ), chartpane, 905, #Thin );
|
|
|
|
|
|
|
#6 | |
|
د جوو ![]() كود:
var Bar: integer;
var lrBar1, lrBar2: integer;
var lrPrice1, lrPrice2: float;
var sd: float;
lrBar1 := BarCount - 66;
lrBar2 := BarCount - 1;
lrPrice2 := LinearReg (BarCount - 1, #close, 65);
lrPrice1 := lrPrice2 - (65 * LinearRegSlope (BarCount - 1, #close, 65));
sd := stddev (BarCount - 1, #close, 65);
DrawLine (lrBar1,lrPrice1,lrBar2,lrPrice2,0, #Red, #solid);
DrawLine (lrBar1,lrPrice1+(1.5*sd),lrBar2,lrPrice2+(1.5*sd),0, #Blue, #solid);
DrawLine (lrBar1,lrPrice1-(1.5*sd),lrBar2,lrPrice2-(1.5*sd),0, #Blue, #solid);
DrawLine (lrBar1,lrPrice1+(3*sd),lrBar2,lrPrice2+(3*sd),0, #Green, #solid);
DrawLine (lrBar1,lrPrice1-(3*sd),lrBar2,lrPrice2-(3*sd),0, #Green, #solid);
print (floattostr (lrPrice2+(3*sd)));
print (floattostr (lrPrice2+(1.5*sd)));
print (floattostr (lrPrice2));
print (floattostr (lrPrice2-(1.5*sd)));
print (floattostr (lrPrice2-(3*sd)));
AnnotateChart ('LR', 0, BarCount - 66, lrPrice1, #blue, 12);
AnnotateChart ('1.5SD', 0, BarCount - 66, lrPrice1+(1.5*sd), #blue, 12);
AnnotateChart ('1.5SD', 0, BarCount - 66, lrPrice1-(1.5*sd), #blue, 12);
AnnotateChart ('3SD', 0, BarCount - 66, lrPrice1+(3*sd), #blue, 12);
AnnotateChart ('3SD', 0, BarCount - 66, lrPrice1-(3*sd), #blue, 12);
|
|
|
|
|
|
|
#7 | |
|
الرينكو ![]() كود:
var Bar, Period: integer;
var Mult, UP_line, DOWN_line, Brick: float;
var RENKO_UP, RENKO_DN: integer;
RENKO_UP:=CreateSeries;
RENKO_DN:=CreateSeries;
Mult:=1;
Period:=10;
for Bar := 3 to BarCount - 1 do
begin
Brick:= Mult*ATR(Bar,Period);
If Bar < 10 then
begin
UP_line:= PriceHigh(Bar);
DOWN_line:= PriceLow(Bar);
Brick:= Mult*(PriceHigh(Bar)-PriceLow(Bar));
@RENKO_UP[Bar]:=UP_line;
@RENKO_DN[Bar]:=DOWN_line;
end;
If Bar > 10 then
begin
if ( PriceClose(Bar) > (UP_line + Brick) ) then begin
UP_line := UP_line + Brick;
DOWN_line:= UP_line - Brick;
@RENKO_UP[Bar]:=UP_line;
@RENKO_DN[Bar]:=DOWN_line;
end;
if ( PriceClose(Bar) < (DOWN_line - Brick) ) then begin
DOWN_line:= DOWN_line - Brick;
UP_line:= DOWN_line + Brick;
@RENKO_UP[Bar]:=UP_line;
@RENKO_DN[Bar]:=DOWN_line;
end;
end;
@RENKO_UP[Bar]:=UP_line;
@RENKO_DN[Bar]:=DOWN_line;
end;
for Bar := 20 to BarCount - 1 do
begin
if not LastPositionActive then
{ Entry Rules }
begin
if @RENKO_UP[Bar] > @RENKO_UP[Bar-1]
then BuyAtMarket( Bar + 1, 'Market' );
if @RENKO_DN[Bar] < @RENKO_DN[Bar-1]
then ShortAtMarket( Bar + 1, 'Market' );
end
else
{ Average-Up Rules }
begin
if ((@RENKO_UP[Bar] > @RENKO_UP[Bar-1]) and PositionLong(LastPosition) )
then BuyAtMarket( Bar + 1, 'Market' );
if ((@RENKO_DN[Bar] < @RENKO_DN[Bar-1]) and PositionShort(LastPosition) )
then ShortAtMarket( Bar + 1, 'Market' );
{ Exit Rules }
if ( (@RENKO_UP[Bar] < @RENKO_UP[Bar-1]) and PositionLong(LastPosition) )
then begin SellAtMarket( Bar + 1, #All, 'Market' );
ShortAtMarket( Bar + 1, 'Market' );
end;
if ( (@RENKO_DN[Bar] > @RENKO_DN[Bar-1]) and PositionShort(LastPosition) )
then begin CoverAtMarket( Bar + 1, #All, 'Market' );
BuyAtMarket( Bar + 1, 'Market' );
end;
end;
end;
// Display Unit
PlotSeries(RENKO_UP, 0, #Red, #Thin );
PlotSeries(RENKO_DN, 0, #Red, #Thin );
|
|
|
|
|
![]() |
| مواقع النشر (المفضلة) |
| الذين يشاهدون محتوى الموضوع الآن : 1 ( الأعضاء 0 والزوار 1) | |
| أدوات الموضوع | |
| انواع عرض الموضوع | |
|
|
المواضيع المتشابهه
|
||||
| الموضوع | كاتب الموضوع | المنتدى | مشاركات | آخر مشاركة |
| متوسطات لبرنامج الويلث . | مزارع | التحليل الفني والأساسي | 4 | 04-06-2010 01:02 AM |
| عقوبة النحلة السكرانة | عذبة السجايا | استراحة اعمال السعوديه | 0 | 03-02-2010 08:38 PM |
| الرائد يهزم النجمة ويتصدرالمجموعة | habob | استراحة اعمال السعوديه | 0 | 12-21-2009 06:35 PM |
| السلاااااااام عليكم بعد غياب أرجع لكم ياأحبتي////العملاق7777///////////////////////// | العملاق7777 | منتدى الاسهم السعوديه | 34 | 04-20-2009 02:27 PM |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27