CMO 錢德動量擺動指標

 


 



1.計算方式
        CMO = (Su - Sd) * 100 / (Su + Sd)
        其中:Su是今日收盤價與昨日收盤價(上漲日)差值加總。
        若當日下跌,則增加值為0;Sd是今日收盤價與做日收盤價(下跌日)
        差值的絕對值加總。若當日上漲,則增加值為0;

2.中文註解
        1、當CMO大於50時,處於超買狀態;當CMO小於50時處於超賣狀態。
        2、CMO的絕對值日越高,趨勢越強。較低的CMO絕對值(0附近)
               標示標的證券在水平方向波動。
        3、投資者還可利用CMO衡量趨勢強度的能力來改進趨勢跟蹤機制。
               例如當CMO的絕對值較高時僅根據趨勢跟蹤指標來操作;
               當COM的絕對值較低時轉而採用交易範圍指標。
3.TS語法
input:n(14),up_limit(50),down_limit(-50);
variable: up(0),down(0),CMO(0),count(0);
up = 0;
down = 0;
for count=0 to n-1 begin
if close[count] > close[count+1] then
up = up + (close[count] - close[count+1]);
if close[count] < close[count+1] then
down = down + (close[count+1] - close[count]);
end;

CMO = ((up-down) / (up + down)) * 100;

if CMO > up_limit then
exitlong next bar at market;
if CMO < down_limit then
buy next bar at market;

if CMO > up_limit then
sell next bar at market;
if CMO < down_limit then
exitshort next bar at market;

 

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 millertime2 的頭像
    millertime2

    miller投資小站~程式交易、外匯期貨研究操作

    millertime2 發表在 痞客邦 留言(0) 人氣()