커뮤니티

문의

프로필 이미지
목마와숙녀
2025-08-01 13:48:30
151
글번호 192928
답변완료
최초 문의를 진입필터라고 해서 혼선을 드린 것 같습니다. 특정 조건이 발생했을 때 b2 진입하는 방법을 하나 더 추가하는 건입니다. b1 진입이 SetStopInactivity로 청산되는 경우에 b2 진입은 답변 수식처럼 진입하는 게 맞습니다. b1 진입이 SetStopInactivity으로 청산되지 않는 경우는 b2 진입은 최초 수식대로 진입해야 합니다. 답변 수식으로는 이 때의 진입이 발생하지 않습니다. 순서도로 보자면 SetStopInactivity이 발생했을 때... b2 진입하는 방법과 SetStopInactivity이 발생하지 않을 때...b2 진입하는 방법(최초 수식) 2개가 필요합니다. 수정 부탁드립니다. > 예스스탁 님이 쓴 글입니다. > 제목 : Re : 문의 > 안녕하세요 예스스탁입니다. input : b1(116); input : b1ls(1.5),b1tr(2.7),mi1(0.5),bg1(150); input : b2(122); input : b2ls(2),b2tr(3.6),mi2(0),bg2(0); var : T1(0),entry(0),LL(0),EH(0); if Bdate != Bdate[1] Then { T1 = TotalTrades; } if MarketPosition == 0 Then entry = TotalTrades-T1; Else entry = (TotalTrades-T1)+1; if MarketPosition == 0 and entry == 0 and C >= daylow+PriceScale*B1 Then buy("b1"); if TotalTrades > TotalTrades[1] Then LL = L; if L < LL Then LL = L; if MarketPosition == 0 and entry == 1 and C >= LL+PriceScale*B2 and C[1] < LL+PriceScale*B2 and c<dayopen-2.5 and IsExitName("StopInactivity",1) == true Then buy("b2"); if MarketPosition== 1 Then { if IsEntryName("b1") == true Then { SetStopLoss(b1ls,PointStop); SetStopTrailing(b1tr,0,PointStop,1); SetStopInactivity(mi1,bg1,PointStop); } Else if IsEntryName("b2") == true Then { SetStopLoss(b2ls,PointStop); SetStopTrailing(b2tr,0,PointStop,1); SetStopInactivity(mi2,bg2,PointStop); } Else { SetStopLoss(0); SetStopTrailing(0,0); SetStopInactivity(0,0); } } 즐거운 하루되세요 > 목마와숙녀 님이 쓴 글입니다. > 제목 : 문의 > 하루 2번 거래하는 수식입니다. 두번째 b2 진입에 필터를 두고 싶습니다. 필터 내용입니다. 1) b1 진입이 SetStopInactivity로 청산되면 b2 진입에 필터가 작동됩니다. 2) b2 진입은 ( c<dayopen-2.5 and b2 진입조건) 이 경우에만 허용됩니다. 항상 고맙습니다. *************************************************************************************** input : b1(116); input : b1ls(1.5),b1tr(2.7),mi1(0.5),bg1(150); input : b2(122); input : b2ls(2),b2tr(3.6),mi2(0),bg2(0); var : T1(0),entry(0),LL(0),EH(0); if Bdate != Bdate[1] Then T1 = TotalTrades; if MarketPosition == 0 Then entry = TotalTrades-T1; Else entry = (TotalTrades-T1)+1; if MarketPosition == 0 and entry == 0 and C >= daylow+PriceScale*B1 Then buy("b1"); if TotalTrades > TotalTrades[1] Then LL = L; if L < LL Then LL = L; if MarketPosition == 0 and entry == 1 and C >= LL+PriceScale*B2 and C[1] < LL+PriceScale*B2 Then buy("b2"); if MarketPosition== 1 Then { if IsEntryName("b1") == true Then { SetStopLoss(b1ls,PointStop); SetStopTrailing(b1tr,0,PointStop,1); SetStopInactivity(mi1,bg1,PointStop); } Else if IsEntryName("b2") == true Then { SetStopLoss(b2ls,PointStop); SetStopTrailing(b2tr,0,PointStop,1); SetStopInactivity(mi2,bg2,PointStop); } Else { SetStopLoss(0); SetStopTrailing(0,0); SetStopInactivity(0,0); } }
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2025-08-01 16:27:12

안녕하세요 예스스탁입니다. input : b1(116); input : b1ls(1.5),b1tr(2.7),mi1(0.5),bg1(150); input : b2(122); input : b2ls(2),b2tr(3.6),mi2(0),bg2(0); var : T1(0),entry(0),LL(0),EH(0); if Bdate != Bdate[1] Then { T1 = TotalTrades; } if MarketPosition == 0 Then entry = TotalTrades-T1; Else entry = (TotalTrades-T1)+1; if MarketPosition == 0 and entry == 0 and C >= daylow+PriceScale*B1 Then buy("b1"); if TotalTrades > TotalTrades[1] Then LL = L; if L < LL Then LL = L; if MarketPosition == 0 and entry == 1 and ((IsEntryName("StopInactivity",1) == False and C >= LL+PriceScale*B2 and C[1] < LL+PriceScale*B2) or (IsExitName("StopInactivity",1) == true and C >= LL+PriceScale*B2 and C[1] < LL+PriceScale*B2 and c<dayopen-2.5)) Then buy("b2"); if MarketPosition== 1 Then { if IsEntryName("b1") == true Then { SetStopLoss(b1ls,PointStop); SetStopTrailing(b1tr,0,PointStop,1); SetStopInactivity(mi1,bg1,PointStop); } Else if IsEntryName("b2") == true Then { SetStopLoss(b2ls,PointStop); SetStopTrailing(b2tr,0,PointStop,1); SetStopInactivity(mi2,bg2,PointStop); } Else { SetStopLoss(0); SetStopTrailing(0,0); SetStopInactivity(0,0); } } 즐거운 하루되세요 > 목마와숙녀 님이 쓴 글입니다. > 제목 : 문의 > 최초 문의를 진입필터라고 해서 혼선을 드린 것 같습니다. 특정 조건이 발생했을 때 b2 진입하는 방법을 하나 더 추가하는 건입니다. b1 진입이 SetStopInactivity로 청산되는 경우에 b2 진입은 답변 수식처럼 진입하는 게 맞습니다. b1 진입이 SetStopInactivity으로 청산되지 않는 경우는 b2 진입은 최초 수식대로 진입해야 합니다. 답변 수식으로는 이 때의 진입이 발생하지 않습니다. 순서도로 보자면 SetStopInactivity이 발생했을 때... b2 진입하는 방법과 SetStopInactivity이 발생하지 않을 때...b2 진입하는 방법(최초 수식) 2개가 필요합니다. 수정 부탁드립니다. > 예스스탁 님이 쓴 글입니다. > 제목 : Re : 문의 > 안녕하세요 예스스탁입니다. input : b1(116); input : b1ls(1.5),b1tr(2.7),mi1(0.5),bg1(150); input : b2(122); input : b2ls(2),b2tr(3.6),mi2(0),bg2(0); var : T1(0),entry(0),LL(0),EH(0); if Bdate != Bdate[1] Then { T1 = TotalTrades; } if MarketPosition == 0 Then entry = TotalTrades-T1; Else entry = (TotalTrades-T1)+1; if MarketPosition == 0 and entry == 0 and C >= daylow+PriceScale*B1 Then buy("b1"); if TotalTrades > TotalTrades[1] Then LL = L; if L < LL Then LL = L; if MarketPosition == 0 and entry == 1 and C >= LL+PriceScale*B2 and C[1] < LL+PriceScale*B2 and c<dayopen-2.5 and IsExitName("StopInactivity",1) == true Then buy("b2"); if MarketPosition== 1 Then { if IsEntryName("b1") == true Then { SetStopLoss(b1ls,PointStop); SetStopTrailing(b1tr,0,PointStop,1); SetStopInactivity(mi1,bg1,PointStop); } Else if IsEntryName("b2") == true Then { SetStopLoss(b2ls,PointStop); SetStopTrailing(b2tr,0,PointStop,1); SetStopInactivity(mi2,bg2,PointStop); } Else { SetStopLoss(0); SetStopTrailing(0,0); SetStopInactivity(0,0); } } 즐거운 하루되세요 > 목마와숙녀 님이 쓴 글입니다. > 제목 : 문의 > 하루 2번 거래하는 수식입니다. 두번째 b2 진입에 필터를 두고 싶습니다. 필터 내용입니다. 1) b1 진입이 SetStopInactivity로 청산되면 b2 진입에 필터가 작동됩니다. 2) b2 진입은 ( c<dayopen-2.5 and b2 진입조건) 이 경우에만 허용됩니다. 항상 고맙습니다. *************************************************************************************** input : b1(116); input : b1ls(1.5),b1tr(2.7),mi1(0.5),bg1(150); input : b2(122); input : b2ls(2),b2tr(3.6),mi2(0),bg2(0); var : T1(0),entry(0),LL(0),EH(0); if Bdate != Bdate[1] Then T1 = TotalTrades; if MarketPosition == 0 Then entry = TotalTrades-T1; Else entry = (TotalTrades-T1)+1; if MarketPosition == 0 and entry == 0 and C >= daylow+PriceScale*B1 Then buy("b1"); if TotalTrades > TotalTrades[1] Then LL = L; if L < LL Then LL = L; if MarketPosition == 0 and entry == 1 and C >= LL+PriceScale*B2 and C[1] < LL+PriceScale*B2 Then buy("b2"); if MarketPosition== 1 Then { if IsEntryName("b1") == true Then { SetStopLoss(b1ls,PointStop); SetStopTrailing(b1tr,0,PointStop,1); SetStopInactivity(mi1,bg1,PointStop); } Else if IsEntryName("b2") == true Then { SetStopLoss(b2ls,PointStop); SetStopTrailing(b2tr,0,PointStop,1); SetStopInactivity(mi2,bg2,PointStop); } Else { SetStopLoss(0); SetStopTrailing(0,0); SetStopInactivity(0,0); } }