TSI-Osc MT4 pour ProRealTime

Forums ProRealTime forum Français Support ProBuilder TSI-Osc MT4 pour ProRealTime

Viewing 2 posts - 1 through 2 (of 2 total)
  • #16989

    Ci-dessous une demande qui a été envoyée à ProRealTime :

    bonjour je vous envoi un indicateur mt4 serait il possible de le coder pour prt
    merci

    —————————————————————–+
    xxx
    double TSI_Buffer[];
    double SignalBuffer[];
    double MTM_Buffer[];
    double EMA_MTM_Buffer[];
    double EMA2_MTM_Buffer[];
    double ABSMTM_Buffer[];
    double EMA_ABSMTM_Buffer[];
    double EMA2_ABSMTM_Buffer[];
    //+——————————————————————+
    //| Custom indicator initialization function                         |
    //+——————————————————————+
    int init()
    {
    //—- indicators
    IndicatorBuffers(8);
    SetIndexBuffer(2, MTM_Buffer);
    SetIndexBuffer(3, EMA_MTM_Buffer);
    SetIndexBuffer(4, EMA2_MTM_Buffer);
    SetIndexBuffer(5, ABSMTM_Buffer);
    SetIndexBuffer(6, EMA_ABSMTM_Buffer);
    SetIndexBuffer(7, EMA2_ABSMTM_Buffer);

    SetIndexStyle(0,DRAW_LINE);
    SetIndexBuffer(0,TSI_Buffer);
    SetIndexLabel(0,”Ergodic”);
    SetIndexStyle(1,DRAW_LINE);
    SetIndexBuffer(1,SignalBuffer);
    SetIndexLabel(1,”Signal”);
    //—-
    return(0);
    }
    //+——————————————————————+
    //| Custor indicator deinitialization function                       |
    //+——————————————————————+
    int deinit()
    {
    //—- TODO: add your code here

    //—-
    return(0);
    }
    //+——————————————————————+
    //| Custom indicator iteration function                              |
    //+——————————————————————+
    int start()
    {
    int    counted_bars=IndicatorCounted();
    int limit,i;
    limit=Bars-counted_bars-1;//Bars
    for (i=Bars-1;i>=0;i–)//Bars
    {
    MTM_Buffer[i]=(Close[i]-Close[i+1]);
    //MTM_Buffer[i]=((High[i]+Low[i])/2)-((High[i+1]+Low[i+1])/2);
    //MTM_Buffer[i]=(((Close[i]-Close[i+1])/Close[i+1])+Point);
    xxx

    //—-
    return(0);
    }
    //+—————————————————————

     

    Et une proposition de réponse :

     

    #16990

    Merci Carl pour ce code. Une autre version de cet indicateur (le True Strength Index) est aussi disponible dans la bibliothèque de codes prorealtime ici : http://www.prorealcode.com/prorealtime-indicators/true-strength-index-tsi/

    Un proche cousin l”Ergodic Oscillator” se trouve également dans la Library à cette adresse : http://www.prorealcode.com/prorealtime-indicators/ergodic-oscillator-smi/

Viewing 2 posts - 1 through 2 (of 2 total)

Create your free account now and post your request to benefit from the help of the community
Register or Login