hi
can you help me get this afl code for doji with conditions please
--------------------------------------------------------------------------------
Software code for the TradeStation Easy Language platform
This code is for the Doji pattern:
Vars: oFastK(0), oSlowK(0), oFastD(0), oSlowD(0);
Value1 = Stochastic(High, Low, Close, 12, 3, 3, 1, oFastK, oSlowK,
oFastD, oSlowD);
If AbsValue(Open - Close) <= Range * 0.1 Then
If Average(Volume, 90) > 200000 Then
If Close > 25 Then
If oSlowK < 20 Then
Plot1(Low, "Doji");
---------------------------------------------------------------
buycond =doji1
buy =IIF((abs(high -low)<= range*0.10 and c>=25 and ma(v,90)>=200000 and stochk(12,3)<20),plot(1,"1",colorred,stylebar);
The first line declares the variables that will be used in the code.
The second line calculates the Stochastic values.
The third line identifies the Doji pattern.
The fourth line requires that at least 200,000 shares of stock
have been traded (on average) for the last 90 days.
The fifth line will require the price to be above 25. This is done
for the purpose of being able to trade options on the stocks
that are found.
The sixth line requires that the stock be in an oversold
condition with the Stochastic below 20.
Be sure to reference oSlowK.
The last line identifies the bar as a Doji.
Before saving the code, it’s important to tell TradeStation how
the Doji will appear on a price chart. This is done under the
‘Properties’ selection under ‘Chart Style’. Make sure the Type is
set to Point. Also, there are 7 choices for Weight, choose at least
#4 or larger.
This code is saved and verified given the name Bigalow Doji.
=======================================
doji plot
idea is locate and find such doji by exploration and see it on chart as well.
can you help me get this afl code for doji with conditions please
--------------------------------------------------------------------------------
Software code for the TradeStation Easy Language platform
This code is for the Doji pattern:
Vars: oFastK(0), oSlowK(0), oFastD(0), oSlowD(0);
Value1 = Stochastic(High, Low, Close, 12, 3, 3, 1, oFastK, oSlowK,
oFastD, oSlowD);
If AbsValue(Open - Close) <= Range * 0.1 Then
If Average(Volume, 90) > 200000 Then
If Close > 25 Then
If oSlowK < 20 Then
Plot1(Low, "Doji");
---------------------------------------------------------------
buycond =doji1
buy =IIF((abs(high -low)<= range*0.10 and c>=25 and ma(v,90)>=200000 and stochk(12,3)<20),plot(1,"1",colorred,stylebar);
The first line declares the variables that will be used in the code.
The second line calculates the Stochastic values.
The third line identifies the Doji pattern.
The fourth line requires that at least 200,000 shares of stock
have been traded (on average) for the last 90 days.
The fifth line will require the price to be above 25. This is done
for the purpose of being able to trade options on the stocks
that are found.
The sixth line requires that the stock be in an oversold
condition with the Stochastic below 20.
Be sure to reference oSlowK.
The last line identifies the bar as a Doji.
Before saving the code, it’s important to tell TradeStation how
the Doji will appear on a price chart. This is done under the
‘Properties’ selection under ‘Chart Style’. Make sure the Type is
set to Point. Also, there are 7 choices for Weight, choose at least
#4 or larger.
This code is saved and verified given the name Bigalow Doji.
=======================================
doji plot
idea is locate and find such doji by exploration and see it on chart as well.
Code:
Range=abs(High-Low);
Buy=Range<= (Range*0.10 )AND C>=25 AND MA(V,90)>=200000 AND StochK(12,3)<20 ;
PlotShapes (IIf(Buy,shapeUpArrow,shapeNone),colorBlue,0,-15);
Filter=Buy;
AddColumn(IIf(Buy,BuyPrice,Null)," Buy1 Signal ", 6.2,1.2,colorGreen);
AddColumn(Close,"Close",1.2);