1.
얼마전 소개했던 스캘핑 전략, 스캘핑 수학에 이은 글입니다. Jonathan Kinlay는 지난 번 글에 이어서 EasyLanguage로 만든 스캘핑 전략을 공개하였습니다.
A Scalping Strategy in E-Mini Futures
국내 투자자들도 많이 사용하는 EasyLanguage로 만든 전략이니까 KOSPI200 선물이나 옵션에 적용해보실 수 있을 듯 합니다. 다만 이런 단서가 붙습니다.
NOTE THE FOLLOWING CAVEATS. DO NOT TRY TO TRADE THIS STRATEGY LIVE (but use it as a basis for a tradable strategy)
2.
EasyLanaguage 소스입니다. 출처는 Easylanguage code for ES scalping strategy 입니다.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 |
// Built for @ES 1 minute chart // Jonathan Kinlay // May 19 2014 // using elsystem; using elsystem.collections; Using elsystem.io ; Using tsdata.marketdata; using tsdata.common; input: Len(10), PTLVticks(30), PTSVticks(2), SLLVticks(2), SLSVticks(30), upperVolThreshold(3), lowerVolThreshold(0.25), StartTime(0800), EndTime(1515);//use exchange time on chart; var: BN(1), PT(0), SL(0), PTv(0.25), SLv(10), plusTrueRange(0), minusTrueRange(0), upsideVol(0), downsideVol(0), upsideFCSTVOL(0), downsideFCSTVOL(0); once clearprintlog; if date <> date[1] then begin BN = 1; end else begin BN += 1; If Close > Close[1] then begin upsideFCSTVOL = plusTrueRange + (plusTrueRange-plusTrueRange[1])*0.5; plusTrueRange = TrueRange; end; If Close < Close[1] then begin downsideFCSTVOL=minusTrueRange + (minusTrueRange-minusTrueRange[1])*0.5; minusTrueRange = TrueRange; end; if BN >= Len -1 and marketposition = 0 and time >= StartTime and upsideFCSTVOL > upperVolThreshold then begin buy("LE LV") 1 contracts next bar at Market; PT = PTLVticks; SL = SLLVticks; end; if BN >= Len - 1 and marketposition = 0 and time >= StartTime and downsideFCSTVOL > upperVolThreshold then begin sellshort("SE LV") 1 contracts next bar at Market; PT = PTLVticks; SL = SLLVticks; end; if BN >= Len -1 and marketposition = 0 and time >= StartTime and upsideFCSTVOL < lowerVolThreshold then begin SellShort("SE SV") 1 contract next bar at InsideAsk Limit; PT = PTSVticks; SL = SLSVticks; end; if BN >= Len -1 and marketposition = 0 and time >= StartTime and downsideFCSTVOL < lowerVolThreshold then begin Buy("LE SV") 1 contract next bar at InsideBid Limit; PT = PTSVticks; SL = SLSVticks; end; PTv = PT* Minmove/Pricescale; SLv = SL*Minmove/Pricescale; setprofittarget(PTv*bigpointvalue); setstoploss(SLv*bigpointvalue); setexitonclose; end; |