Trend Intensity Index という指標
公開日:
:
最終更新日:2015/02/24
マネー
Schaff Trend Cycle について調べていたら、似たような指標 Trend Intensity Index について書かれたブログを見つけました。
> Trend Intensity IndexにAlert をつける。
早速、インディケーターの TII_RLH.mq4 をダウンロードさせていただき、自前の EA に組み込んでみました。
バックテストを行うと、これが過去最高の成績に。
USDJPY 1時間足 2014/1/1~2015/1/1
なんと、プロフィットファクター 2.97!
勝率も44%となかなかいい。
ドローダウンも低めで安心感があります。
ちょっと改良しがいがありそうです。
GBPJPY H4 も成績がいいです。
GBPJPY H4 2014/1/1-2015/1/1
Minor_period =7, Major_period = 20 に変更しています。
プロフィットファクター 3.06!投資資金 3.8倍は魅力的。
しめしめと思ったら落とし穴が・・・
関連記事
- Trend Intensity Index という指標(2) シグナルを付加
- スローな TII にしてくれ
- Trend Intensity Index を使った EA
- Trend Intensity Index を使った EA(2) Damiani filter版
プログラムソース(重大なバグあり使用不可)
//
// yasciiTII01
// 動作にはTII_RLH.mq4 が必要
//マジックナンバーの定義
#define MAGIC 42235
//パラメーターの設定//
extern double Lots = 1.0; //取引ロット数
extern int Slip = 10; //許容スリッページ数
extern string Comments = "TII01"; //コメント
extern int Major_Period=18;
extern int Minor_Period=12;
int Major_MaMode=1; //0=sma, 1=ema, 2=smma, 3=lwma, 4=lsma
extern int Major_PriceMode=0;//0=close, 1=open, 2=high, 3=low, 4=median(high+low)/2, 5=typical(high+low+close)/3, 6=weighted(high+low+close+close)/4
color LevelColor=Silver;
extern int BuyLevel=35;
int MidLevel=50;
extern int SellLevel=75;
extern int Fast_period = 14 ;
extern double margin = 0.0 ;
extern double ILC = 100.0 ;
// extern double TP = 1100 ;
//変数の設定//
int Ticket_L = 0; //買い注文の結果をキャッチする変数
int Ticket_S = 0; //売り注文の結果をキャッチする変数
int Exit_L = 0; //買いポジションの決済注文の結果をキャッチする変数
int Exit_S = 0; //売りポジションの決済注文の結果をキャッチする変数
int OS1 ;
int OS2 ;
double OOPL;
double OOPS;
int start(){
//暴落対策(始め)
double FastHH1 = Close[iHighest(NULL, 0, MODE_CLOSE, Fast_period, 1)];
double FastLL1 = Close[iLowest(NULL, 0, MODE_CLOSE, Fast_period, 1)];
//買いポジションのエグジット
OS1 = OrderSelect(Ticket_L, SELECT_BY_TICKET);
if( Bid < FastLL1-margin
&& ( Ticket_L != 0 && Ticket_L != -1 ))
{
Exit_L = OrderClose(Ticket_L,Lots,Bid,Slip,Red);
if( Exit_L ==1 ) {Ticket_L = 0;}
}
//売りポジションのエグジット
OS2 = OrderSelect(Ticket_S, SELECT_BY_TICKET);
if( Ask> FastHH1+margin
&& ( Ticket_S != 0 && Ticket_S != -1 ))
{
Exit_S = OrderClose(Ticket_S,Lots,Ask,Slip,Blue);
if( Exit_S ==1 ) {Ticket_S = 0;}
}
//暴落対策(終わり)
if (Volume[0]>1 || IsTradeAllowed() == false) return(0) ;
double tii1 = iCustom(NULL, 0,"TII_RLH", Major_Period, Major_MaMode, Major_PriceMode, Minor_Period, LevelColor , BuyLevel, MidLevel , SellLevel, 0 , 1);
double tii2 = iCustom(NULL, 0,"TII_RLH", Major_Period, Major_MaMode, Major_PriceMode, Minor_Period, LevelColor , BuyLevel, MidLevel , SellLevel, 0 , 2);
double tii3 = iCustom(NULL, 0,"TII_RLH", Major_Period, Major_MaMode, Major_PriceMode, Minor_Period, LevelColor , BuyLevel, MidLevel , SellLevel, 0 , 3);
double tii4 = iCustom(NULL, 0,"TII_RLH", Major_Period, Major_MaMode, Major_PriceMode, Minor_Period, LevelColor , BuyLevel, MidLevel , SellLevel, 0 , 4);
double tiiSM1 = (tii1+tii2+tii3) / 3.0 ;
double tiiSM2 = (tii4+tii2+tii3) / 3.0 ;
double lc = ILC;
if(( Digits ==3 ) ||(Digits ==5)) lc = lc*10.0 ;
//買いポジションのエグジット
OS1 = OrderSelect(Ticket_L, SELECT_BY_TICKET);
OOPL = OrderOpenPrice();
if( ((tii1 < SellLevel && tii2 > SellLevel) || ( OOPL - lc*Point >= Close[1] ) ) //|| ( OOPL+TP <= Close[1] ))
&& ( Ticket_L != 0 && Ticket_L != -1 ))
{
Exit_L = OrderClose(Ticket_L,Lots,Bid,Slip,Red);
if( Exit_L ==1 ) {Ticket_L = 0;}
}
//売りポジションのエグジット
OS2 = OrderSelect(Ticket_S, SELECT_BY_TICKET);
OOPS = OrderOpenPrice();
if( ((tii1 > BuyLevel && tii2 < BuyLevel )||( OOPS + lc*Point <= Close[1] ) ) //|| ( OrderOpenPrice()-TP >= Close[1] ))
&& ( Ticket_S != 0 && Ticket_S != -1 ))
{
Exit_S = OrderClose(Ticket_S,Lots,Ask,Slip,Blue);
if( Exit_S ==1 ) {Ticket_S = 0;}
}
//買いエントリー
if( ((tii1 > BuyLevel && tii2 < BuyLevel) || (tii1 > tiiSM1 && tii2 < tiiSM2) )
&& ( Ticket_L == 0 || Ticket_L == -1 )
&& ( Ticket_S == 0 || Ticket_S == -1 ))
{
Ticket_L = OrderSend(Symbol(),OP_BUY,Lots,Ask,Slip,0,0,Comments,MAGIC,0,Red);
}
//売りエントリー
if(( (tii1 < SellLevel && tii2 > SellLevel) || (tii1 < tiiSM1 && tii2 > tiiSM2))
&& ( Ticket_S == 0 || Ticket_S == -1 )
&& ( Ticket_L == 0 || Ticket_L == -1 ))
{
Ticket_S = OrderSend(Symbol(),OP_SELL,Lots,Bid,Slip,0,0,Comments,MAGIC,0,Blue);
}
return(0);
}
###
関連記事
-
-
[FX] 12月に入って相場急変
11/8 から先週(11/30)まで続いたドル円上昇相場(上図はドル円 15分足 )が今週か
-
-
[FX] 外為ファイネストで「早起きは5pipsの得」
1時間ほど前に開いた外為ファイネストのデモ口座ですが、「早起きは5pipsの得」を稼働させて
-
-
【FX】なつかしの Vulkan Profit インジケーター
Vulkan Profit というインジケーターは有名なので大昔から知っているのですが、そのロジック
-
-
移動平均線とVQインディケーターとの組み合わせで自動売買(2)
USDCHF 1時間足[/caption] ↑ クリックすると拡大します 以前のス
-
-
【FX】Monopolist という EA
久々に FX の話です。 MQL5 で売られている Monopolist という EA ですが
-
-
2865,2866,2868 の話
「2865,2866,2868 の話」とはなにか。 2865 は GXNDXカバコ
-
-
【FX】AXI Select Seedステージ卒業
プロップファームの AXI Select のお話。 一昨日「なかなかエッジスコアが上がらない(
-
-
【FX】ほぼストキャス単独での EA
ストキャスティクスという指標があります。 売買サインが早く出るのでスキャルピング愛好家には好評
-
-
【高配当株】 楽天SCHD 9/18発表とか
WAT さんの動画で詳しく紹介されているのを本日観ましたが、米国の高配当ETF で有名な SCHD
-
-
【FX】AXI Select なかなかエッジスコアが上がらない(あと一歩)
しばらく放置しているプロップファームの AXI Select のお話。 なかなかエッジスコアが
- PREV
- スイスフラン暴騰騒動(2)
- NEXT
- 西の関ヶ原 / 滝口 康彦










