• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Kase Peak Oscilator

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

    Kase Peak Oscilator

    Hello my friends,

    I would like to add in NT an indicator called the Kase Peak Oscilator. Because I'm a novice to create a new indicator, is there anybody who could tell me step by step how to do that ?

    Thanks

    Angel



    This is below the FREE formula found on
    http://trader.online.pl/ELZ/t-i-Kase...cillator.html:


    Kase Peak Oscillator by Cynthia Case


    Origin: omega-list
    Written by: James Rehler
    Date found: 8 dec 97
    {The following code is what I cobbled together after reading her articles in Futures mag.}



    Type : Function, Name : StdDevx

    inputs :
    Price(NumericSeries),
    Length(NumericSimple);

    vars :
    SumSqr(0),
    Avg(0),
    Counter(0);

    if Length <> 0
    then begin
    Avg = Average(Price,Length);
    SumSqr = 0;
    for counter = 0 to Length - 1
    begin
    SumSqr = SumSqr + (Price[counter]-Avg) * (Price[counter]-Avg);
    end;
    StdDevX = SquareRoot(SumSqr / (Length-1));
    end
    else
    StdDevX = 0;





    Type : Indicator, Name : Kase Peak Oscillator


    inputs:LEN(30), Smooth(3), Strength(1);
    vars: RWH(0), RWL(0),PEAK(0), MEAN(0), STD(0);

    RWH = (H[0] - L[LEN]) / (AvgTrueRange(LEN) * SquareRoot(LEN));
    RWL = (H[LEN] - L[0]) / (AvgTrueRange(LEN) * SquareRoot(LEN));
    PEAK = WAverage((RWH - RWL),3);
    MEAN = average(PEAK,LEN);
    STD = StdDevx(PEAK,LEN);

    if (MEAN + (1.33 * STD)) > 2.08 then value1 = (MEAN + (1.33 * STD))
    else value1 = 2.08;

    if (MEAN - (1.33 * STD)) < -1.92 then value2 = (MEAN - (1.33 * STD))
    else value2 = -1.92;

    plot1(PEAK,"PeakOsc");
    if PEAK[1] >= 0 and PEAK > 0 then plot2(value1,"+/-97.5%");
    if PEAK[1] <= 0 and PEAK < 0 then plot2(value2,"+/-97.5%");

    #2
    Kase Peak Oscilator and KCD.....

    Hello,

    I'm sorry because I forgot in my previous post to include with the Kase Peak Oscilator the KCD because they work TOGETHER .

    Thanks

    Angel



    The free formula of the KCD is :

    Kase CD by Cynthia Case

    Origin: omega-list
    Written by: James Rehler
    Date found: 8 dec 97
    {The following code is what I cobbled together after reading her articles in Futures mag.}



    Type : Indicator, Name : Kase CD

    inputs:
    LEN(30),
    Smooth(3),
    Strength(1);

    vars:
    RWH(0),
    RWL(0),
    PEAK(0),
    KCD(0);

    RWH = (H[0] - L[LEN]) / (AvgTrueRange(LEN) * SquareRoot(LEN));
    RWL = (H[LEN] - L[0]) / (AvgTrueRange(LEN) * SquareRoot(LEN));

    PEAK = WAverage((RWH - RWL),Smooth);
    KCD = (PEAK) - average(Peak,8);

    plot1(KCD,"KCD");
    plot2(0,"Zero");

    if CheckAlert then begin
    if BullishDivergence(low,plot1,Strength,15) = 1
    then Alert = true;
    if BearishDivergence(high,plot1,Strength,15) = 1
    then Alert = true;
    end;

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by gbux11, Today, 02:36 AM
    1 response
    11 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by NinjaCustomer, 05-09-2019, 08:54 AM
    4 responses
    65 views
    0 likes
    Last Post Harry
    by Harry
     
    Started by Mike3238, Yesterday, 07:09 PM
    1 response
    20 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by Rashid Garuba, Today, 11:37 AM
    0 responses
    8 views
    0 likes
    Last Post Rashid Garuba  
    Started by elkhatabi, Today, 11:19 AM
    0 responses
    5 views
    0 likes
    Last Post elkhatabi  
    Working...
    X