커뮤니티

예스랭귀지로 변환 부탁드립니다.

프로필 이미지
바둑이
2023-01-01 21:06:53
842
글번호 164983
답변완료
Params : Profit_Target( 90 ), Stop_Loss( 40 ); param : BuyA_iLen(20) , ExitLongA_iLen(15), SellA_iLen(20), ExitShortA_iLen(15); param : BuyA_ChoiceType(0), ExitLongA_ChoiceType(1) ; param : SellA_ChoiceType(1) , ExitShortA_ChoiceType(0); param : Margin(0.00) , cut_amt(1), loss_limit(-100); // cut_amt param : Time_start(160000) , time_end(050000), time_exit1(051000) ; var : time_now(0) , Trading_time(False), all_exit(False) , Daily_vari(False), Buy_ok(False) , Sell_ok(False) ; var : yesterday_low(0) , yesterday_high(0) ; var : today_low(0) , today_high(0) ; var : yesterday_close(0) ; var : check_01(0), check_02(0),check_03(0),check_04(0),check_05(0); Var : TickSize( 0 ); TickSize = OneTick * PriceScale; ////////////////////////////////////////////////////////////////////////// // 매수진입 [BuyA : 종가봉 20 갱신, ] ////////////////////////////////////////////////////////////////////////// var : BuyA_V1(0), BuyA_V2(0), BuyA_Result(FALSE); BuyA_V1 = Highest(High, BuyA_iLen); BuyA_V2 = Lowest(Low, BuyA_iLen); BuyA_Result = Close > BuyA_V1[1]; if ( BuyA_Result = true ) Then Buy("Buy"); ////////////////////////////////////////////////////////////////////////// // 매수청산 [ExitLongA : 종가봉 15 갱신, ] ////////////////////////////////////////////////////////////////////////// var : ExitLongA_V1(0), ExitLongA_V2(0), ExitLongA_Result(FALSE); ExitLongA_V1 = Highest(High, ExitLongA_iLen); ExitLongA_V2 = Lowest(Low, ExitLongA_iLen); ExitLongA_Result = Close < ExitLongA_V2[1]; if ( ExitLongA_Result = true ) Then ExitLong(""); ////////////////////////////////////////////////////////////////////////// // 매도진입 [SellA : 종가봉 20 갱신, ] ////////////////////////////////////////////////////////////////////////// var : SellA_V1(0), SellA_V2(0), SellA_Result(FALSE); SellA_V1 = Highest(High, SellA_iLen); SellA_V2 = Lowest(Low, SellA_iLen); SellA_Result = Close < SellA_V2[1]; if ( SellA_Result = true ) Then Sell("Sell"); ////////////////////////////////////////////////////////////////////////// // 매도청산 [ExitShortA : 종가봉 15 갱신, ] ////////////////////////////////////////////////////////////////////////// var : ExitShortA_V1(0), ExitShortA_V2(0), ExitShortA_Result(FALSE); ExitShortA_V1 = Highest(High, ExitShortA_iLen); ExitShortA_V2 = Lowest(Low, ExitShortA_iLen); ExitShortA_Result = FALSE; ExitShortA_Result = Close > ExitShortA_V1[1]; if ( ExitShortA_Result = true ) Then ExitShort(""); SetStopProfitTarget( Profit_Target * TickSize ); SetStopLoss( Stop_Loss * TickSize );
시스템
답변 1
프로필 이미지

예스스탁 예스스탁 답변

2023-01-02 15:13:49

안녕하세요. 예스스탁 입니다. Input : Profit_Target(90), Stop_Loss(40); Input : BuyA_iLen(20), ExitLongA_iLen(15), SellA_iLen(20), ExitShortA_iLen(15); Input : BuyA_ChoiceType(0), ExitLongA_ChoiceType(1); Input : SellA_ChoiceType(1), ExitShortA_ChoiceType(0); Input : Margin(0.00) , cut_amt(1), loss_limit(-100); // cut_amt Input : Time_start(160000) , time_end(050000), time_exit1(051000) ; var : time_now(0) , Trading_time(False), all_exit(False) , Daily_vari(False),Buy_ok(False) , Sell_ok(False) ; var : yesterday_low(0) , yesterday_high(0) ; var : today_low(0) , today_high(0) ; var : yesterday_close(0) ; var : check_01(0), check_02(0),check_03(0),check_04(0),check_05(0); Var : TickSize(0); TickSize = PriceScale; ////////////////////////////////////////////////////////////////////////// // 매수진입 [BuyA : 종가봉 20 갱신, ] ////////////////////////////////////////////////////////////////////////// var : BuyA_V1(0), BuyA_V2(0), BuyA_Result(FALSE); BuyA_V1 = Highest(High, BuyA_iLen); BuyA_V2 = Lowest(Low, BuyA_iLen); BuyA_Result = Close > BuyA_V1[1]; if BuyA_Result == true Then Buy("Buy"); ////////////////////////////////////////////////////////////////////////// // 매수청산 [ExitLongA : 종가봉 15 갱신, ] ////////////////////////////////////////////////////////////////////////// var : ExitLongA_V1(0), ExitLongA_V2(0), ExitLongA_Result(FALSE); ExitLongA_V1 = Highest(High, ExitLongA_iLen); ExitLongA_V2 = Lowest(Low, ExitLongA_iLen); ExitLongA_Result = Close < ExitLongA_V2[1]; if ExitLongA_Result == true Then ExitLong(""); ////////////////////////////////////////////////////////////////////////// // 매도진입 [SellA : 종가봉 20 갱신, ] ////////////////////////////////////////////////////////////////////////// var : SellA_V1(0), SellA_V2(0), SellA_Result(FALSE); SellA_V1 = Highest(High, SellA_iLen); SellA_V2 = Lowest(Low, SellA_iLen); SellA_Result = Close < SellA_V2[1]; if SellA_Result == true Then Sell("Sell"); ////////////////////////////////////////////////////////////////////////// // 매도청산 [ExitShortA : 종가봉 15 갱신, ] ////////////////////////////////////////////////////////////////////////// var : ExitShortA_V1(0), ExitShortA_V2(0), ExitShortA_Result(FALSE); ExitShortA_V1 = Highest(High, ExitShortA_iLen); ExitShortA_V2 = Lowest(Low, ExitShortA_iLen); ExitShortA_Result = FALSE; ExitShortA_Result = Close > ExitShortA_V1[1]; if ExitShortA_Result == true Then ExitShort(""); SetStopProfitTarget( Profit_Target * TickSize, PointStop ); SetStopLoss( Stop_Loss * TickSize, PointStop ); 즐거운 하루 보내세요. > 바둑이 님이 쓴 글입니다. > 제목 : 예스랭귀지로 변환 부탁드립니다. > Params : Profit_Target( 90 ), Stop_Loss( 40 ); param : BuyA_iLen(20) , ExitLongA_iLen(15), SellA_iLen(20), ExitShortA_iLen(15); param : BuyA_ChoiceType(0), ExitLongA_ChoiceType(1) ; param : SellA_ChoiceType(1) , ExitShortA_ChoiceType(0); param : Margin(0.00) , cut_amt(1), loss_limit(-100); // cut_amt param : Time_start(160000) , time_end(050000), time_exit1(051000) ; var : time_now(0) , Trading_time(False), all_exit(False) , Daily_vari(False), Buy_ok(False) , Sell_ok(False) ; var : yesterday_low(0) , yesterday_high(0) ; var : today_low(0) , today_high(0) ; var : yesterday_close(0) ; var : check_01(0), check_02(0),check_03(0),check_04(0),check_05(0); Var : TickSize( 0 ); TickSize = OneTick * PriceScale; ////////////////////////////////////////////////////////////////////////// // 매수진입 [BuyA : 종가봉 20 갱신, ] ////////////////////////////////////////////////////////////////////////// var : BuyA_V1(0), BuyA_V2(0), BuyA_Result(FALSE); BuyA_V1 = Highest(High, BuyA_iLen); BuyA_V2 = Lowest(Low, BuyA_iLen); BuyA_Result = Close > BuyA_V1[1]; if ( BuyA_Result = true ) Then Buy("Buy"); ////////////////////////////////////////////////////////////////////////// // 매수청산 [ExitLongA : 종가봉 15 갱신, ] ////////////////////////////////////////////////////////////////////////// var : ExitLongA_V1(0), ExitLongA_V2(0), ExitLongA_Result(FALSE); ExitLongA_V1 = Highest(High, ExitLongA_iLen); ExitLongA_V2 = Lowest(Low, ExitLongA_iLen); ExitLongA_Result = Close < ExitLongA_V2[1]; if ( ExitLongA_Result = true ) Then ExitLong(""); ////////////////////////////////////////////////////////////////////////// // 매도진입 [SellA : 종가봉 20 갱신, ] ////////////////////////////////////////////////////////////////////////// var : SellA_V1(0), SellA_V2(0), SellA_Result(FALSE); SellA_V1 = Highest(High, SellA_iLen); SellA_V2 = Lowest(Low, SellA_iLen); SellA_Result = Close < SellA_V2[1]; if ( SellA_Result = true ) Then Sell("Sell"); ////////////////////////////////////////////////////////////////////////// // 매도청산 [ExitShortA : 종가봉 15 갱신, ] ////////////////////////////////////////////////////////////////////////// var : ExitShortA_V1(0), ExitShortA_V2(0), ExitShortA_Result(FALSE); ExitShortA_V1 = Highest(High, ExitShortA_iLen); ExitShortA_V2 = Lowest(Low, ExitShortA_iLen); ExitShortA_Result = FALSE; ExitShortA_Result = Close > ExitShortA_V1[1]; if ( ExitShortA_Result = true ) Then ExitShort(""); SetStopProfitTarget( Profit_Target * TickSize ); SetStopLoss( Stop_Loss * TickSize );