안녕하세요?
새해복 많이받으십시요.
아래수식에서 기존 진입조건에서 이평선2개를 넣어서
정배열시 매도, 역배열시 매수를 추가로 하고싶습니다.
감사합니다.
input : b기준선(0.05),s기준선(0.95),n(3);
var : entry(0);
if Bdate != Bdate[1] Then
entry = 0;
var1 = C%1;
var2 = C%1;
if (MarketPosition != 0 and MarketPosition != MarketPosition[1]) or
(MarketPosition == MarketPosition[1] and TotalTrades > TotalTrades[1]) Then
entry = entry+1;
if entry < n Then
{
if MarketPosition == 0 and C > O and b기준선 == var1 then
Buy();
if MarketPosition == 0 and C < O and s기준선 == Var2 then
Sell();
}
input : 익절틱수(50),손절틱수(50);
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
답변 1
예스스탁
예스스탁 답변
2021-01-05 09:25:16
안녕하세요
예스스탁입니다.
input : b기준선(0.05),s기준선(0.95),n(3),P1(5),P2(20);
var : entry(0);
if Bdate != Bdate[1] Then
entry = 0;
var1 = C%1;
var2 = C%1;
value1 = ma(C,P1);
value2 = ma(C,P2);
if (MarketPosition != 0 and MarketPosition != MarketPosition[1]) or
(MarketPosition == MarketPosition[1] and TotalTrades > TotalTrades[1]) Then
entry = entry+1;
if entry < n Then
{
if MarketPosition == 0 and C > O and b기준선 == var1 and value1 < Value2 then
Buy();
if MarketPosition == 0 and C < O and s기준선 == Var2 and value1 > Value2 then
Sell();
}
input : 익절틱수(50),손절틱수(50);
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);
즐거운 하루되세요
> 대구어린울프 님이 쓴 글입니다.
> 제목 : 추가부탁드립니다.
> 안녕하세요?
새해복 많이받으십시요.
아래수식에서 기존 진입조건에서 이평선2개를 넣어서
정배열시 매도, 역배열시 매수를 추가로 하고싶습니다.
감사합니다.
input : b기준선(0.05),s기준선(0.95),n(3);
var : entry(0);
if Bdate != Bdate[1] Then
entry = 0;
var1 = C%1;
var2 = C%1;
if (MarketPosition != 0 and MarketPosition != MarketPosition[1]) or
(MarketPosition == MarketPosition[1] and TotalTrades > TotalTrades[1]) Then
entry = entry+1;
if entry < n Then
{
if MarketPosition == 0 and C > O and b기준선 == var1 then
Buy();
if MarketPosition == 0 and C < O and s기준선 == Var2 then
Sell();
}
input : 익절틱수(50),손절틱수(50);
SetStopProfittarget(PriceScale*익절틱수,PointStop);
SetStopLoss(PriceScale*손절틱수,PointStop);