커뮤니티

문의드립니다

프로필 이미지
cjfdk
2024-01-01 19:05:16
886
글번호 175330
답변완료
Input: 손절(20), 익절(40), 몇번까지(7); Input: n1(1), n2(2), n3(3), n4(4), n5(5), n6(6), n7(12), n8(24), n9(48); var: 매수조건(false), 매도조건(false),vol(0),s(0),x(0); var1 = rsi(10); 매수조건 = MarketPosition == 0 and CrossUp(var1,30); 매도조건 = MarketPosition == 0 and CrossDown(var1,70); if 매수조건 Then { Buy("b1",OnClose,Def,n1); s = c; x = 1; } if 매도조건 Then { Sell("s1",OnClose,Def,n1); s = c; x = 1; } if MarketPosition != 0 and MarketPosition[1] != 0 and MarketPosition != MarketPosition[1] Then x = x+1; if MarketPosition == 1 Then { ExitLong("bp",AtLimit,s+익절); if x == 1 Then vol = n2; if x == 2 Then vol = n3; if x == 3 Then vol = n4; if x == 4 Then vol = n5; if x == 5 Then vol = n6; if x == 6 Then vol = n7; if x == 7 Then vol = n8; if x == 8 Then vol = n9; if x < 몇번까지 Then sell("bs",AtStop,s-손절,vol); } if MarketPosition == -1 Then { ExitShort("sp",AtLimit,s-익절); if x == 1 Then vol = n2; if x == 2 Then vol = n3; if x == 3 Then vol = n4; if x == 4 Then vol = n5; if x == 5 Then vol = n6; if x == 6 Then vol = n7; if x == 7 Then vol = n8; if x == 8 Then vol = n9; if x < 몇번까지 Then Buy("sb",AtStop,s+손절,vol); } 수고 많으십니다 위 시스템 rsi 를 기반으로 작동하는데 rsi를 지우고 예스에서 제공하는 Boll Bands Bearish 로 바꿀수 있나요? 항상 감사드립니다
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2024-01-02 16:23:28

안녕하세요 예스스탁입니다. Inputs: Length(9), StdDev(2), Bars(2); Input: 손절(20), 익절(40), 몇번까지(7); Input: n1(1), n2(2), n3(3), n4(4), n5(5), n6(6), n7(12), n8(24), n9(48); var: vol(0),s(0),x(0); Variables: BBTop(0),BBBot(0); BBTop = BollBandup(Length, StdDev); BBBot = BollBanddown(Length, StdDev); If MarketPosition == 0 and CountIF(Close < BBBot, Bars) == Bars Then Buy("B1", AtStop, BBBot); if MarketPosition == 0 and CountIF(Close > BBTop, Bars) == Bars Then Sell("S1", AtStop, BBTop,n1); if MarketPosition != 0 and MarketPosition[1] != 0 and MarketPosition != MarketPosition[1] Then x = x+1; if MarketPosition == 1 Then { if MarketPosition[1] != MarketPosition[1] and IsEntryName("B1") == true Then { s = LatestEntryPrice(0); x = 1; } ExitLong("bp",AtLimit,s+익절); if x == 1 Then vol = n2; if x == 2 Then vol = n3; if x == 3 Then vol = n4; if x == 4 Then vol = n5; if x == 5 Then vol = n6; if x == 6 Then vol = n7; if x == 7 Then vol = n8; if x == 8 Then vol = n9; if x < 몇번까지 Then sell("bs",AtStop,s-손절,vol); } if MarketPosition == -1 Then { if MarketPosition[1] != MarketPosition[1] and IsEntryName("S1") == true Then { s = LatestEntryPrice(0); x = 1; } ExitShort("sp",AtLimit,s-익절); if x == 1 Then vol = n2; if x == 2 Then vol = n3; if x == 3 Then vol = n4; if x == 4 Then vol = n5; if x == 5 Then vol = n6; if x == 6 Then vol = n7; if x == 7 Then vol = n8; if x == 8 Then vol = n9; if x < 몇번까지 Then Buy("sb",AtStop,s+손절,vol); } 즐거운 하루되세요 > cjfdk 님이 쓴 글입니다. > 제목 : 문의드립니다 > Input: 손절(20), 익절(40), 몇번까지(7); Input: n1(1), n2(2), n3(3), n4(4), n5(5), n6(6), n7(12), n8(24), n9(48); var: 매수조건(false), 매도조건(false),vol(0),s(0),x(0); var1 = rsi(10); 매수조건 = MarketPosition == 0 and CrossUp(var1,30); 매도조건 = MarketPosition == 0 and CrossDown(var1,70); if 매수조건 Then { Buy("b1",OnClose,Def,n1); s = c; x = 1; } if 매도조건 Then { Sell("s1",OnClose,Def,n1); s = c; x = 1; } if MarketPosition != 0 and MarketPosition[1] != 0 and MarketPosition != MarketPosition[1] Then x = x+1; if MarketPosition == 1 Then { ExitLong("bp",AtLimit,s+익절); if x == 1 Then vol = n2; if x == 2 Then vol = n3; if x == 3 Then vol = n4; if x == 4 Then vol = n5; if x == 5 Then vol = n6; if x == 6 Then vol = n7; if x == 7 Then vol = n8; if x == 8 Then vol = n9; if x < 몇번까지 Then sell("bs",AtStop,s-손절,vol); } if MarketPosition == -1 Then { ExitShort("sp",AtLimit,s-익절); if x == 1 Then vol = n2; if x == 2 Then vol = n3; if x == 3 Then vol = n4; if x == 4 Then vol = n5; if x == 5 Then vol = n6; if x == 6 Then vol = n7; if x == 7 Then vol = n8; if x == 8 Then vol = n9; if x < 몇번까지 Then Buy("sb",AtStop,s+손절,vol); } 수고 많으십니다 위 시스템 rsi 를 기반으로 작동하는데 rsi를 지우고 예스에서 제공하는 Boll Bands Bearish 로 바꿀수 있나요? 항상 감사드립니다