Ichimoku + RSI

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #39614 quote
    Rafa
    Participant
    Senior

    Estoy estudiando una estrategia que funciona muy bien, y me gustaría hacer el SCREENER pero no se por qué motivo no funciona del todo como a mi me gustaría.

    Consiste en entrar en aquellos cruces del RSI con una EMA, dependiendo del Ichimoku: Posiciones Largas, Cruce del RSI en largo, por encima de la nube: para posiciones cortas lo mismo pero al revés

    I am studying a strategy which works very good, and I would like to code the SCREENER, but I don´t know why is not working in the way I would like.

    The strategy is to take positions when the RSI crosses an EMA, depending of the Ichimoku: Long, when the RSI crosses the EMA long direction, above the Kumo: For short positions is the same but opposite

    //****************************************************************
    //*  Estrategia de cruce de RSI y su EMA  a cualquier nivel
    //*  Autor: Rafa Barreto
    //****************************************************************
    
    // ===== VALORES MODIFICABLES =====
    
    ValorRSI = 10
    ValorEMA = 10
    
    
    // -- Construyendo la graficación Ichimoku --
    // -- Valores NO Standar: Fibonacci: 8; 21; 55 --
    // -- Valores NO Standar: Actuales : 7;22;44
    // -- Valores Standar: 9; 26; 52
    
    PeriodoCorto = 7
    PeriodoMedio = 22
    PeriodoLargo = 44
    
    Tenkan = (highest[PeriodoCorto](High) + lowest[PeriodoCorto](Low)) / 2
    Kijun = (highest[PeriodoMedio](High) + lowest[PeriodoMedio](Low)) / 2
    SpanA = (TenKan[PeriodoMedio] + Kijun[PeriodoMedio]) / 2
    SpanB = (highest[PeriodoLargo](High[PeriodoMedio]) + lowest[PeriodoLargo](Low[PeriodoMedio])) / 2
    Chikou = Close
    
    // ===== A partir de aquí no se toca el código =====
    
    // --- Variables de la estrategia ---
    
    MiRSI = RSI[ValorRSI](close)
    MiEMARSI = ExponentialAverage[ValorEMA](RSI[ValorRSI](close))
    
    // --- Condiciones de Posiciones Largas ---
    
    Condicion1Larga = (close  > SpanA) AND (close  > SpanB)
    Condicion2Larga = (Tenkan > SpanA) AND (Tenkan > SpanB)
    Condicion3Larga = (Kijun  > SpanA) AND (Kijun  > SpanB)
    Condicion4Larga = (Chikou > SpanA) AND (Chikou > SpanB)
    
    IF (Condicion1Larga AND Condicion2Larga AND Condicion3Larga AND Condicion4Larga) THEN
    
    CruceLargo = MiRSI CROSSES OVER MiEMARSI
    
    ENDIF
     
    // -- Condiciones de Posiciones Cortas ---
    
    Condicion1Corta = (close  < SpanA) AND (close  < SpanB)
    Condicion2Corta = (Tenkan < SpanA) AND (Tenkan < SpanB)
    Condicion3Corta = (Kijun  < SpanA) AND (Kijun  < SpanB)
    Condicion4Corta = (Chikou < SpanA) AND (Chikou < SpanB)
    
    IF (Condicion1Corta AND Condicion2Corta AND Condicion3Corta AND Condicion4Corta) THEN
    
    CruceCorto = MiRSI CROSSES UNDER MiEMARSI
    
    ENDIF
    
    // ===== SCREENER =====
    
    SCREENER [CruceLargo OR CruceCorto]
    
    #39615 quote
    Rafa
    Participant
    Senior

    Solo funciona con el OIL pero no con el FOREX, Por qué?

    #39650 quote
    Nicolas
    Keymaster
    Legend

    El problema es que sólo prueba el RSI y el promedio móvil pasa o cruza bajo cuando todas las demás condiciones son verdaderas. Así que todas las condiciones podrían ser probadas en el pasado y nunca ser reajustado una vez que las condiciones ichimoku no son verdaderas de nuevo.
    Esta versión de código debería funcionar mejor creo, por favor confirme! 🙂

    //****************************************************************
    //*  Estrategia de cruce de RSI y su EMA  a cualquier nivel
    //*  Autor: Rafa Barreto
    //****************************************************************
    
    // ===== VALORES MODIFICABLES =====
    
    ValorRSI = 10
    ValorEMA = 10
    
    
    // -- Construyendo la graficación Ichimoku --
    // -- Valores NO Standar: Fibonacci: 8; 21; 55 --
    // -- Valores NO Standar: Actuales : 7;22;44
    // -- Valores Standar: 9; 26; 52
    
    PeriodoCorto = 7
    PeriodoMedio = 22
    PeriodoLargo = 44
    
    Tenkan = (highest[PeriodoCorto](High) + lowest[PeriodoCorto](Low)) / 2
    Kijun = (highest[PeriodoMedio](High) + lowest[PeriodoMedio](Low)) / 2
    SpanA = (TenKan[PeriodoMedio] + Kijun[PeriodoMedio]) / 2
    SpanB = (highest[PeriodoLargo](High[PeriodoMedio]) + lowest[PeriodoLargo](Low[PeriodoMedio])) / 2
    Chikou = Close
    
    // ===== A partir de aquí no se toca el código =====
    
    // --- Variables de la estrategia ---
    
    MiRSI = RSI[ValorRSI](close)
    MiEMARSI = ExponentialAverage[ValorEMA](MiRSI)
    
    // --- Condiciones de Posiciones Largas ---
    
    Condicion1Larga = (close  > SpanA) AND (close  > SpanB)
    Condicion2Larga = (Tenkan > SpanA) AND (Tenkan > SpanB)
    Condicion3Larga = (Kijun  > SpanA) AND (Kijun  > SpanB)
    Condicion4Larga = (Chikou > SpanA) AND (Chikou > SpanB)
    
    CruceLargo = MiRSI CROSSES OVER MiEMARSI and (Condicion1Larga AND Condicion2Larga AND Condicion3Larga AND Condicion4Larga)
     
    // -- Condiciones de Posiciones Cortas ---
    
    Condicion1Corta = (close  < SpanA) AND (close  < SpanB)
    Condicion2Corta = (Tenkan < SpanA) AND (Tenkan < SpanB)
    Condicion3Corta = (Kijun  < SpanA) AND (Kijun  < SpanB)
    Condicion4Corta = (Chikou < SpanA) AND (Chikou < SpanB)
    
    CruceCorto = MiRSI CROSSES UNDER MiEMARSI and (Condicion1Corta AND Condicion2Corta AND Condicion3Corta AND Condicion4Corta)
    
    // ===== SCREENER =====
    
    SCREENER [CruceLargo OR CruceCorto]
    #39661 quote
    Rafa
    Participant
    Senior

    Muchas Gracias Nicolás, te mantendré informado

    #39664 quote
    Rafa
    Participant
    Senior

    Gracias Nicolás funciona de maravilla 🙂

    #68419 quote
    Eusebio Garcia Nuez
    Participant
    New

    hola y como seria el indicador

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.
ProRealAI ProRealAI New

Stuck on this ProBuilder code?

Describe what this topic is trying to build, in plain English, and ProRealAI writes the ProRealTime™ indicator, screener or system for you.

Available in 7 languages
Try ProRealAI

Ichimoku + RSI


ProScreener: Buscadores de Mercado y Rastreo

New Reply
Author
author-avatar
Rafa @rafa Participant
Summary

This topic contains 5 replies,
has 3 voices, and was last updated by Eusebio Garcia Nuez
8 years, 5 months ago.

Topic Details
Forum: ProScreener: Buscadores de Mercado y Rastreo
Language: Spanish
Started: 07/03/2017
Status: Active
Attachments: No files
Logo Logo
Loading...