매매마감 시간이 아래는 9:30 으로 되어있는데이걸 변수로 넣고 싶습니다.
그리고 매매 횟수 entry도 변수로 지정 가능할까요?
부탁드리겠습니다.
감사합니다!!
input : 손절(1.1),익절(2.8);
var : entry(0,Data1);
if Bdate != Bdate[1] Then
entry = 0;
if (MarketPosition != 0 and MarketPosition != MarketPosition[1]) or
(MarketPosition == MarketPosition[1] and TotalTrades > TotalTrades[1]) Then
entry = entry+1;
if Data1(sTime >= 90000 and sTime < 93000 and entry < 3) Then
{
if data2(c) >= 3 Then
Buy();
if data2(c) <= -3 Then
Sell();
}
if Data2(c) < 0 Then
ExitLong();
if Data2(c) > 0 Then
ExitShort();
SetStopProfittarget(익절,PointStop);
SetStoploss(손절,PointStop);
답변 1
예스스탁
예스스탁 답변
2021-02-19 16:35:53
안녕하세요
예스스탁입니다.
input : 손절(1.1),익절(2.8);
input : 마감시간(93000);
var : entry(0,Data1);
if Bdate != Bdate[1] Then
entry = 0;
if (MarketPosition != 0 and MarketPosition != MarketPosition[1]) or
(MarketPosition == MarketPosition[1] and TotalTrades > TotalTrades[1]) Then
entry = entry+1;
if Data1(sTime >= 90000 and sTime < 마감시간 and entry < 3) Then
{
if data2(c) >= 3 Then
Buy();
if data2(c) <= -3 Then
Sell();
}
if Data2(c) < 0 Then
ExitLong();
if Data2(c) > 0 Then
ExitShort();
SetStopProfittarget(익절,PointStop);
SetStoploss(손절,PointStop);
즐거운 하루되세요
> 캣피쉬 님이 쓴 글입니다.
> 제목 : 변수로 넣고 싶습니다.
>
매매마감 시간이 아래는 9:30 으로 되어있는데이걸 변수로 넣고 싶습니다.
그리고 매매 횟수 entry도 변수로 지정 가능할까요?
부탁드리겠습니다.
감사합니다!!
input : 손절(1.1),익절(2.8);
var : entry(0,Data1);
if Bdate != Bdate[1] Then
entry = 0;
if (MarketPosition != 0 and MarketPosition != MarketPosition[1]) or
(MarketPosition == MarketPosition[1] and TotalTrades > TotalTrades[1]) Then
entry = entry+1;
if Data1(sTime >= 90000 and sTime < 93000 and entry < 3) Then
{
if data2(c) >= 3 Then
Buy();
if data2(c) <= -3 Then
Sell();
}
if Data2(c) < 0 Then
ExitLong();
if Data2(c) > 0 Then
ExitShort();
SetStopProfittarget(익절,PointStop);
SetStoploss(손절,PointStop);