커뮤니티
부탁드립니다.
2015-05-13 14:44:16
131
글번호 85990
input : g(11),r(25),s(2),P(10);
var : SMIV(0),SMIS(0);
SMIv = ema(ema(c-(highest(H,g) + lowest(L,g))*0.5, r),s) * 100 /
(0.5 * ema(ema(highest(H,g)-lowest(L,g),r),s)) ;
SMIS = ema(SMIV,p);
if stime >= 200000 or stime < 030000 then{
if crossup(SMIV,SMIS) Then
buy();
if CrossDown(SMIV,SMIS) Then
sell();
}
SetStopLoss(PriceScale*30,PointStop);
if MarketPosition == 1 Then{
if highest(h,BarsSinceEntry) >= EntryPrice+PriceScale*20 Then
ExitLong("bx",AtStop,EntryPrice+PriceScale*1);
}
if MarketPosition == -1 Then{
if Lowest(l,BarsSinceEntry) <= EntryPrice-PriceScale*20 Then
ExitShort("sx",AtStop,EntryPrice-PriceScale*1);
}
상기 시스템에서 손절을 30틱으로 해서 작성해주신 수식입니다.
혹, 시스템신호 발생이 완성봉기준이라면
손절가를 완성봉의 시가를 기준으로 -10틱을 설정하고싶읍니다.
(매수매도 공히)
- 상기 시간은 우리나라 시간으로 설정된거죠?
- 상기 트레일링은 진입가 기준으로 2틱 익절로 알고있는데..
수익 최고가 대비 25틱 이 내려오면 익절되게끔 부탁드립니다.
미리 감사드립니다.
답변 1
예스스탁 예스스탁 답변
2015-05-13 19:34:39
안녕하세요
예스스탁입니다.
1.
현재 작성된 식은 진입은 봉완성시
청산들은 모두 미완성시에 가격조건만족하면 즉시 신호가 발생합니다.
진입봉의 시가를 기준으로 10틱 손절이시면 아래식 이용하시면 됩니다.
input : g(11),r(25),s(2),P(10);
var : SMIV(0),SMIS(0);
SMIv = ema(ema(c-(highest(H,g) + lowest(L,g))*0.5, r),s) * 100 /
(0.5 * ema(ema(highest(H,g)-lowest(L,g),r),s)) ;
SMIS = ema(SMIV,p);
if stime >= 200000 or stime < 030000 then{
if crossup(SMIV,SMIS) Then
buy();
if CrossDown(SMIV,SMIS) Then
sell();
}
if MarketPosition == 1 Then{
exitlong("BL",AtStop,O[BarsSinceEntry]-PriceScale*10);
if highest(h,BarsSinceEntry) >= EntryPrice+PriceScale*20 Then
ExitLong("bx",AtStop,EntryPrice+PriceScale*1);
}
if MarketPosition == -1 Then{
ExitShort("SL",AtStop,O[BarsSinceEntry]+PriceScale*10);
if Lowest(l,BarsSinceEntry) <= EntryPrice-PriceScale*20 Then
ExitShort("sx",AtStop,EntryPrice-PriceScale*1);
}
2,
수식에서는 시간값만 지정이 됩니다.
사용자분이 차트를 한국시간으로 설정하시면 됩니다.
해외선물이시면 차트창속성의 배경탭에
차트의 기준시간을 지정하는 부분이 있습니다.
기준시간을 한국시간으로 지정하시면 됩니다.
3
기존식은 20틱이상 수익이 발생한후
수익이 감소하면 1틱수익에서 청산되게 되어 있습니다.
매수이후 최고가 대비-25틱에서 청산
매수이후 최저가 대비+25틱에서 청산
을 추가한 식입니다.
input : g(11),r(25),s(2),P(10);
var : SMIV(0),SMIS(0);
SMIv = ema(ema(c-(highest(H,g) + lowest(L,g))*0.5, r),s) * 100 /
(0.5 * ema(ema(highest(H,g)-lowest(L,g),r),s)) ;
SMIS = ema(SMIV,p);
if stime >= 200000 or stime < 030000 then{
if crossup(SMIV,SMIS) Then
buy();
if CrossDown(SMIV,SMIS) Then
sell();
}
if MarketPosition == 1 Then{
exitlong("BL",AtStop,O[BarsSinceEntry]-PriceScale*10);
exitlong("Btr",AtStop,highest(h,BarsSinceEntry)-PriceScale*25);
if highest(h,BarsSinceEntry) >= EntryPrice+PriceScale*20 Then
ExitLong("bx",AtStop,EntryPrice+PriceScale*1);
}
if MarketPosition == -1 Then{
ExitShort("SL",AtStop,O[BarsSinceEntry]+PriceScale*10);
ExitShort("Str",AtStop,lowest(L,BarsSinceEntry)+PriceScale*25);
if Lowest(l,BarsSinceEntry) <= EntryPrice-PriceScale*20 Then
ExitShort("sx",AtStop,EntryPrice-PriceScale*1);
}
즐거운 하루되세요
> vmfha 님이 쓴 글입니다.
> 제목 : 부탁드립니다.
>
input : g(11),r(25),s(2),P(10);
var : SMIV(0),SMIS(0);
SMIv = ema(ema(c-(highest(H,g) + lowest(L,g))*0.5, r),s) * 100 /
(0.5 * ema(ema(highest(H,g)-lowest(L,g),r),s)) ;
SMIS = ema(SMIV,p);
if stime >= 200000 or stime < 030000 then{
if crossup(SMIV,SMIS) Then
buy();
if CrossDown(SMIV,SMIS) Then
sell();
}
SetStopLoss(PriceScale*30,PointStop);
if MarketPosition == 1 Then{
if highest(h,BarsSinceEntry) >= EntryPrice+PriceScale*20 Then
ExitLong("bx",AtStop,EntryPrice+PriceScale*1);
}
if MarketPosition == -1 Then{
if Lowest(l,BarsSinceEntry) <= EntryPrice-PriceScale*20 Then
ExitShort("sx",AtStop,EntryPrice-PriceScale*1);
}
상기 시스템에서 손절을 30틱으로 해서 작성해주신 수식입니다.
혹, 시스템신호 발생이 완성봉기준이라면
손절가를 완성봉의 시가를 기준으로 -10틱을 설정하고싶읍니다.
(매수매도 공히)
- 상기 시간은 우리나라 시간으로 설정된거죠?
- 상기 트레일링은 진입가 기준으로 2틱 익절로 알고있는데..
수익 최고가 대비 25틱 이 내려오면 익절되게끔 부탁드립니다.
미리 감사드립니다.