커뮤니티
문의합니다
2011-07-19 13:26:09
709
글번호 41091
안녕하세요
현재의식에서
선물2분봉
Input : af(0.02), maxAF(0.2);
Var : value(0);
value = sar(af,maxAF);
If (stime > 90000 and stime < 144900) THEN {
# 매수/매도청산
if C > value Then
{
Buy("b");
}
# 매도/매수청산
if C < value Then
{
Sell("s");
}
if MarketPosition == 1 and BarsSinceEntry == 2 Then
var1 = countif(C > O,2);
Else
var1 = 0;
if MarketPosition == -1 and BarsSinceEntry == 2 Then
var2 = countif(C < O,2);
Else
var2 = 0;
if ((MarketPosition == 0) or (MarketPosition == -1 and var2 < 0)) and C > value[1] then
buy();
if ((MarketPosition == 0) or (MarketPosition == 1 and var1 < 0)) and C < value[1] then
sell();
}
SetStopTrailing(0.02,1,PointStop);
후 다음봉에서 매수매도 가능할수있게 또 스위칭도가능할수 있도록 수정부탁드림니다
}
답변 3
예스스탁 예스스탁 답변
2011-07-19 16:40:22
안녕하세요
예스스탁입니다.
Input : af(0.02), maxAF(0.2);
Var : value(0);
value = sar(af,maxAF);
If (stime > 90000 and stime < 144900) THEN {
# 매수/매도청산
if C > value Then
{
Buy("b");
}
# 매도/매수청산
if C < value Then
{
Sell("s");
}
if MarketPosition == 1 and BarsSinceEntry == 2 Then
var1 = countif(C > O,2);
Else
var1 = 0;
if MarketPosition == -1 and BarsSinceEntry == 2 Then
var2 = countif(C < O,2);
Else
var2 = 0;
if ((MarketPosition == 0) or (MarketPosition == -1 and var2 < 0)) and C > value[1] then
buy();
if ((MarketPosition == 0) or (MarketPosition == 1 and var1 < 0)) and C < value[1] then
sell();
}
if MarketPosition == 0 and BarsSinceExit(1) == 1 and ExitDate(1) == sdate and IsExitName("StopTrailing",1) Then{
if MarketPosition(1) == 1 Then
sell();
if MarketPosition(1) == -1 Then
buy();
}
SetStopTrailing(0.02,1,PointStop);
즐거운 하루되세요
> 외국인 님이 쓴 글입니다.
> 제목 : 문의합니다
> 안녕하세요
현재의식에서
선물2분봉
Input : af(0.02), maxAF(0.2);
Var : value(0);
value = sar(af,maxAF);
If (stime > 90000 and stime < 144900) THEN {
# 매수/매도청산
if C > value Then
{
Buy("b");
}
# 매도/매수청산
if C < value Then
{
Sell("s");
}
if MarketPosition == 1 and BarsSinceEntry == 2 Then
var1 = countif(C > O,2);
Else
var1 = 0;
if MarketPosition == -1 and BarsSinceEntry == 2 Then
var2 = countif(C < O,2);
Else
var2 = 0;
if ((MarketPosition == 0) or (MarketPosition == -1 and var2 < 0)) and C > value[1] then
buy();
if ((MarketPosition == 0) or (MarketPosition == 1 and var1 < 0)) and C < value[1] then
sell();
}
SetStopTrailing(0.02,1,PointStop);
후 다음봉에서 매수매도 가능할수있게 또 스위칭도가능할수 있도록 수정부탁드림니다
}
외국인
2011-07-19 17:16:54
##직전청산이 SetStopProfittarget이고 전일 생긴 청산
Condition2 = IsExitName("StopTrailing",1) and ExitDate(1) == sdate;
//-------------------------------------------------------------------------------------------
#직전청산이 SetStopProfittarget이고 현재무포지션이고 매도포지션이고 직전청산후 1개봉 경과 후이거나 직전청산이 SetStopProfittarget이 아님
Condition3 = (Condition2 == true and MarketPosition == 0 and MarketPosition == -1 and BarsSinceExit(1) >= 1) or (Condition2 == false);
//-----------------------------------------------------------------------------------------------------------
##직전청산이 SetStopProfittarget이고 현재무포지션이고 현재 매수포지션상태이고 직전청산후 1개봉 경과 후이거나 직전청산이 SetStopProfittarget이 아님
Condition4 = (Condition2 == true and MarketPosition == 0 and MarketPosition == 1 and BarsSinceExit(1) >= 1) or (Condition2 == false);
이수식도가능한지요
> 예스스탁 님이 쓴 글입니다.
> 제목 : Re : 문의합니다
> 안녕하세요
예스스탁입니다.
Input : af(0.02), maxAF(0.2);
Var : value(0);
value = sar(af,maxAF);
If (stime > 90000 and stime < 144900) THEN {
# 매수/매도청산
if C > value Then
{
Buy("b");
}
# 매도/매수청산
if C < value Then
{
Sell("s");
}
if MarketPosition == 1 and BarsSinceEntry == 2 Then
var1 = countif(C > O,2);
Else
var1 = 0;
if MarketPosition == -1 and BarsSinceEntry == 2 Then
var2 = countif(C < O,2);
Else
var2 = 0;
if ((MarketPosition == 0) or (MarketPosition == -1 and var2 < 0)) and C > value[1] then
buy();
if ((MarketPosition == 0) or (MarketPosition == 1 and var1 < 0)) and C < value[1] then
sell();
}
if MarketPosition == 0 and BarsSinceExit(1) == 1 and ExitDate(1) == sdate and IsExitName("StopTrailing",1) Then{
if MarketPosition(1) == 1 Then
sell();
if MarketPosition(1) == -1 Then
buy();
}
SetStopTrailing(0.02,1,PointStop);
즐거운 하루되세요
> 외국인 님이 쓴 글입니다.
> 제목 : 문의합니다
> 안녕하세요
현재의식에서
선물2분봉
Input : af(0.02), maxAF(0.2);
Var : value(0);
value = sar(af,maxAF);
If (stime > 90000 and stime < 144900) THEN {
# 매수/매도청산
if C > value Then
{
Buy("b");
}
# 매도/매수청산
if C < value Then
{
Sell("s");
}
if MarketPosition == 1 and BarsSinceEntry == 2 Then
var1 = countif(C > O,2);
Else
var1 = 0;
if MarketPosition == -1 and BarsSinceEntry == 2 Then
var2 = countif(C < O,2);
Else
var2 = 0;
if ((MarketPosition == 0) or (MarketPosition == -1 and var2 < 0)) and C > value[1] then
buy();
if ((MarketPosition == 0) or (MarketPosition == 1 and var1 < 0)) and C < value[1] then
sell();
}
SetStopTrailing(0.02,1,PointStop);
후 다음봉에서 매수매도 가능할수있게 또 스위칭도가능할수 있도록 수정부탁드림니다
}
예스스탁 예스스탁 답변
2011-07-20 10:10:42
안녕하세요
예스스탁입니다.
어떤 내용의 가능여부를 문의하시는지 모르겠습니다.
좀더 자세한 내용을 올려주시기 바랍니다.
즐거운 하루되세요
> 외국인 님이 쓴 글입니다.
> 제목 : Re : Re : 문의합니다
> ##직전청산이 SetStopProfittarget이고 전일 생긴 청산
Condition2 = IsExitName("StopTrailing",1) and ExitDate(1) == sdate;
//-------------------------------------------------------------------------------------------
#직전청산이 SetStopProfittarget이고 현재무포지션이고 매도포지션이고 직전청산후 1개봉 경과 후이거나 직전청산이 SetStopProfittarget이 아님
Condition3 = (Condition2 == true and MarketPosition == 0 and MarketPosition == -1 and BarsSinceExit(1) >= 1) or (Condition2 == false);
//-----------------------------------------------------------------------------------------------------------
##직전청산이 SetStopProfittarget이고 현재무포지션이고 현재 매수포지션상태이고 직전청산후 1개봉 경과 후이거나 직전청산이 SetStopProfittarget이 아님
Condition4 = (Condition2 == true and MarketPosition == 0 and MarketPosition == 1 and BarsSinceExit(1) >= 1) or (Condition2 == false);
이수식도가능한지요
> 예스스탁 님이 쓴 글입니다.
> 제목 : Re : 문의합니다
> 안녕하세요
예스스탁입니다.
Input : af(0.02), maxAF(0.2);
Var : value(0);
value = sar(af,maxAF);
If (stime > 90000 and stime < 144900) THEN {
# 매수/매도청산
if C > value Then
{
Buy("b");
}
# 매도/매수청산
if C < value Then
{
Sell("s");
}
if MarketPosition == 1 and BarsSinceEntry == 2 Then
var1 = countif(C > O,2);
Else
var1 = 0;
if MarketPosition == -1 and BarsSinceEntry == 2 Then
var2 = countif(C < O,2);
Else
var2 = 0;
if ((MarketPosition == 0) or (MarketPosition == -1 and var2 < 0)) and C > value[1] then
buy();
if ((MarketPosition == 0) or (MarketPosition == 1 and var1 < 0)) and C < value[1] then
sell();
}
if MarketPosition == 0 and BarsSinceExit(1) == 1 and ExitDate(1) == sdate and IsExitName("StopTrailing",1) Then{
if MarketPosition(1) == 1 Then
sell();
if MarketPosition(1) == -1 Then
buy();
}
SetStopTrailing(0.02,1,PointStop);
즐거운 하루되세요
> 외국인 님이 쓴 글입니다.
> 제목 : 문의합니다
> 안녕하세요
현재의식에서
선물2분봉
Input : af(0.02), maxAF(0.2);
Var : value(0);
value = sar(af,maxAF);
If (stime > 90000 and stime < 144900) THEN {
# 매수/매도청산
if C > value Then
{
Buy("b");
}
# 매도/매수청산
if C < value Then
{
Sell("s");
}
if MarketPosition == 1 and BarsSinceEntry == 2 Then
var1 = countif(C > O,2);
Else
var1 = 0;
if MarketPosition == -1 and BarsSinceEntry == 2 Then
var2 = countif(C < O,2);
Else
var2 = 0;
if ((MarketPosition == 0) or (MarketPosition == -1 and var2 < 0)) and C > value[1] then
buy();
if ((MarketPosition == 0) or (MarketPosition == 1 and var1 < 0)) and C < value[1] then
sell();
}
SetStopTrailing(0.02,1,PointStop);
후 다음봉에서 매수매도 가능할수있게 또 스위칭도가능할수 있도록 수정부탁드림니다
}
다음글
이전글