답변완료
부틱드립니다
수고하십니다
아래수식에서 첫번째(cs==1),두번쩨(cs==1)를
Plot1(Var1);Plot2(Var2);로 수식부탁드립니다
input : 기간(14);
var : S(0),R(0),u70(0),u50(0),순번조건(False);
var : cs(Nan),조건(False);
S=Accum(1);
R=Rsi(기간);//14
if CrossUp(R,70) Then
u70 = S;
if CrossDown(R,50) Then
u50 = S;
순번조건=U70<u50 ;
if 순번조건 && 순번조건[1] == False Then
cs = 0;
if Crossup(R,50) Then
cs = cs+1;
조건= cs==1;//※첫번째
if 조건 and 조건[1] ==False Then
var1 = O;
Plot1(Var1);
답변완료
수정부탁드립니다. 오류가 너무 많네요.;.ㅠㅠ
Inputs:
ADX_Period(14),
ADX_Level(25),
RSI_Period(14),
RSI_Overbought(70),
RSI_Oversold(30),
Vol_Period(20),
OI_Period(20),
Bids_Period(5),
Asks_Period(5),
Profit_Target(200),
Stop_Loss(100);
Vars:
ADX_Value(0),
RSI_Value(0),
Vol_Avg(0),
OI_Avg(0),
Bids_Avg(0),
Asks_Avg(0);
ADX_Value = ADX(ADX_Period);
RSI_Value = RSI(RSI_Period, 1);
Vol_Avg = MA(V, Vol_Period);
OI_Avg = MA(OI, OI_Period);
Bids_Avg = MA(bids, Bids_Period);
Asks_Avg = MA(asks, Asks_Period);
ConditionBuy_1 = ADX_Value > ADX_Level;
ConditionBuy_2 = RSI_Value < RSI_Overbought;
ConditionBuy_3 = Bids_Avg > Asks_Avg;
ConditionBuy_4 = V > Vol_Avg;
ConditionBuy_5 = OI > OI_Avg;
if ConditionBuy_1 AND ConditionBuy_2 AND ConditionBuy_3 AND ConditionBuy_4 AND ConditionBuy_5 Then
Buy();
ConditionSell_1 = ADX_Value > ADX_Level;
ConditionSell_2 = RSI_Value > RSI_Oversold;
ConditionSell_3 = Asks_Avg > Bids_Avg;
ConditionSell_4 = V > Vol_Avg;
ConditionSell_5 = OI > OI_Avg;
if ConditionSell_1 AND ConditionSell_2 AND ConditionSell_3 AND ConditionSell_4 AND ConditionSell_5 Then
Sell();
if MarketPosition == 1 Then
{
if ADX_Value < ADX_Value[1] Then
ExitAll();
if C - EntryPrice >= Profit_Target * PriceScale Then
ExitAll();
if C - EntryPrice <= -Stop_Loss * PriceScale Then
ExitAll();
}
if MarketPosition == -1 Then
{
if ADX_Value < ADX_Value[1] Then
ExitAll();
if EntryPrice - C >= Profit_Target * PriceScale Then
ExitAll();
if EntryPrice - C <= -Stop_Loss * PriceScale Then
ExitAll();
}
답변완료
수식변환요청드립니다
수고많습니다 수식을검색식으로 부탁드립니다
smoothadd=ma_length+if(smoothingbool,ma_lengthsmoothing,0);
ms=if(ma_type==1,ma(c,smoothadd),
if(ma_type==2,eavg(c,smoothadd),
if(ma_type==3,ma(c,smoothadd,가중),eavg(c,smoothadd))));
tolerance_r=ms*toleranceinputr;
prev_below=c(1)<=ms(1)+tolerance_r;
curr_above=c>ms+tolerance_r;
prev_below && curr_above
ma_length 120
ma_lengthsmoothing 25
smoothingbool 0
ma_type 2
toleranceinputr 0.0025