Buy if the price has fallen

Buy if the price has fallen

We buy when the price is below the EMA200 and above the EMA50 (sik!).
As a filter we use a simple linear regression slope.
We sell when the price is above the EMA28 and below the EMA7.

It really couldn’t be easier

thats all for today
until then

Share this

Risk disclosure:

No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.

ProRealTime ITF files and other attachments : How to import ITF files into ProRealTime platform?

PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials

  1. Richk87 • 02/15/2022 #

    Hi John, I like the code a lot, but i can only get it to work cumulateorders in backtesting. It doesn’t do it in live situation. Any reason why?
    Many thanks
    Rich

  2. Desastrader • 02/15/2022 #

    Da error en la linea 9 🙁

  3. JohnScher • 02/15/2022 #

    If you import the itf.file the code works very well, with a big loss at the end based to the attack of Russia on Ukraine

  4. adconsulting • 02/15/2022 #

    Ciao John. grazie per la condivisione. Sul DAX A 4 H HO FATTO PICCOLE MODIFICHE E RISULTATI SONO OTTIMI ANCHE CON NOTIZIE NEGATIVE COME LA GUERRA IN UCRAINA, TI COPIO DI SEGUITO IL CODICE:

    defparam cumulateorders = true // false is working well

    once ordersize = 1

    TradingDay = ((dayofweek=1 and (time=050000 or time=090000 or time=130000 or time=170000)) or (dayofweek=2 and (time=010000 or time=050000 or time=130000 or time=170000)) or (dayofweek=3 and (time=090000 or time=130000 or time=210000)) or (dayofweek=4 and time=050000) or (dayofweek=5 and (time=010000 or time=090000 or time=130000 or time=170000)))
    //TradingTime = time >= 090000 and time Exponentialaverage [45] (close)
    c2 = close close [1]
    c4 = LinearRegressionSlope[95] (close) < 0

    IF TradingDay then
    If c1 and c2 and c3 and c4 then
    buy ordersize contract at market
    Endif
    ENDIF

    c5 = close Exponentialaverage [21] (close)

    IF longonmarket then
    If c5 and c6 then
    sell at market
    Endif
    Endif

    Set Stop %Loss 5.50 //as insurance
    Set Target %profit 2.75

    //*****************************************************************
    if close>open then
    marginebv=low-130
    elsif close<open then
    marginebv= low-115
    endif
    //tp=300
    //stopbv=200
    //acquistobreck= LOW-margine
    //acquistobv= close -marginebv

    if longonmarket then
    sell at marginebv stop
    endif

  5. adconsulting • 02/15/2022 #

    SCUSA . ECCO IL CODICE
    defparam cumulateorders = true // false is working well

    once ordersize = 1

    TradingDay = ((dayofweek=1 and (time=050000 or time=090000 or time=130000 or time=170000)) or (dayofweek=2 and (time=010000 or time=050000 or time=130000 or time=170000)) or (dayofweek=3 and (time=090000 or time=130000 or time=210000)) or (dayofweek=4 and time=050000) or (dayofweek=5 and (time=010000 or time=090000 or time=130000 or time=170000)))
    //TradingTime = time >= 090000 and time <= 170000

    c1 = close > Exponentialaverage [45] (close)
    c2 = close < Exponentialaverage [100] (close)
    c3 = close > close [1]
    c4 = LinearRegressionSlope[95] (close) < 0

    IF TradingDay then
    If c1 and c2 and c3 and c4 then
    buy ordersize contract at market
    Endif
    ENDIF

    c5 = close < Exponentialaverage [9] (close)
    c6 = close > Exponentialaverage [21] (close)

    IF longonmarket then
    If c5 and c6 then
    sell at market
    Endif
    Endif

    Set Stop %Loss 5.50 //as insurance
    Set Target %profit 2.75

    //*****************************************************************
    if close>open then
    marginebv=low-130
    elsif close<open then
    marginebv= low-115
    endif
    //tp=300
    //stopbv=200
    //acquistobreck= LOW-margine
    //acquistobv= close -marginebv

    if longonmarket then
    sell at marginebv stop
    endif

  6. wally • 02/15/2022 #

    Hola soy nuevo en el mudo robots. Alguien seria tan amable de poner el archivo itf.file ya que sin él no sé como poner el código en el PRT. GRACIAS!!

  7. Darren Nash • 02/15/2022 #

    I found this works well on the DOW

  8. thomas2004ch • 02/15/2022 #

    Hi John,

    Is your strategy suitable for daily SPY?

    Regards

  9. gatowman • 319 days ago #

    Hi, ich bin leider Anfänger, habe den Code zwar importiert, aber scheinbar läuft er nicht auf D1, was muss ich ändern, oder kann jemand den code auf D1 oder W1 umschreiben, danke.

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar
Related users ' posts
Nicolas it is based on seasonality of DAX.
Luciano Santiago Juárez Hello I am new here I am trying to understand this code IF monthlyMultiplierLong > 0 ...
Luciano Santiago Juárez Sorry the code copied bad the line I dont understand is: ELSIF monthlyMultiplierLong 0 THEN
verdi55 Is there such a thing as a free lunch ?
maceng Thanks Nicolas for this great work! I would like to understand the math behind it in order t...
Nicolas Sorry I have no time to provide assistance for python programmers. Have a good day.
Maz Hi all, firstly happy to know that this is helping you. I look into updating it for PRT11 wh...
Nicolas just use 3 times a linear regression channel code you will find in the library.
leederbyshire Here's the link to alternative linear regression channel indicator Nicolas is referring to t...
Wing Yes, investigate as much as you want. For more insight, you can view the linet1, linet2 etc....
CKW Hi Wing, Thanks for your sharing. I am still trying to breakdown & understand your code...
Wing Hello CKW. No, the parameter, 7 in this case, is used when calling the RSI indicator to ide...
Nacho Buenos días Raul, tengo puesto este sistema desde hace unos días en una cuenta demo en la ve...
Dominik Hola Raul ... it looks wonderful :-) Why does it not work if I use less than 100,000 € capi...
Bobbi Hola y gracias por compartir! Descubrí que en 5 minutos teníamos algo muy bueno! Pero no ...
Nicolas Thanks for contributing to the "ichimoku section" of the prorealtime code library Don't he...
sourberry Thank you , this is a great indicator works beautifully. Could you kindly modify to scr...
pp_playaflamenca Excuse me,... reading your code about spanB: [ SenkouSpanBFutureW = (Highest[SenkouSpanPerio...
danhei Hi I am tryong to figure out how trist strategy works. I am new to pro real time. Can some...
Plop61 Hello,Thank you for sharing this beautiful strategy.Is it possible to indicate the code for ...
NoName Thank you very much for this fascinating trading system. It is still proving to be extremely...
ALE
8 years ago
pollon Ciao Ale,  anche a me da questo errore  "QQE_QUDAX1HBUY"  "QQE_QUDAX1HSELL"  "UNIV_QUDAX...
reb Hi Ale do you trade these QU strategies?  Are the results same as backtests Thnaks in adv...
avatar
crazytrader Hi anyone that has run this lately?
larouedegann best with this hour IF TIME =081000 THEN plushaut=highest[2](high) plusbas = lowest[2](lo...
CanAny1Trade Hi! I'm trying to put together a similar indicator but struggling. I want to mark the NY Pit...
ALE Hi Pat This code was nothing more than an experiment
pat95162 Hi Ale Do you have same results as me ? The strategy works very well in 2017 and now in 2-...
Nicolas Built on the history means that it suits the history. Always develop ideas in In-Sample peri...
ALE
8 years ago
ALE no, only with TF 15m
enzo_52 Grazie tante, Thanks so much 
JanWd Hallo Ale, First of all, thank you for this strategy. Could you explain what the BLUSTER ...
Elsborgtrading No that is wrong :) 1st runs always- then only run 2nd if 1st is on market with positions(ar...
Elsborgtrading It can only be fully automated if IG change minimum SLto 7 at night on DAX multi timefra...
Elsborgtrading A small example. the strategy would have opened 3 position on Dec 4th 2016 and keept it for ...
Cosmic1
9 years ago
Cosmic1 @JadeDB What times are you putting in?
sincitytrader I tried this one out recently,  and wasn't profitable for me.
Cosmic1 Yes, not great lately. I stopped this live at the end of last year. Will wait to see when th...
Philip Raphael Hey! Thank so much for sharing this wonderful indicator! I have always tried to code a simil...
CKW Hi Philip, What do you mean "Years" are not defined ? candle? If to code yearly candle size...
dakaodo Years not defined was probably b/c Phillip copied and pasted the code into PRT instead of im...
Mansoor What does COI stand for?
MikeGC Hi Mansoor, COI is the abbreviation for the Coppock indicator.
nonetheless Anyone interested in this strategy please see forum topic: https://www.prorealcode.com/topic...
zilliq The reasons why I think it's time consuming and we loose time to try to do backests and Auto...
filiprb Hello Zilliq, You don't need a system to produce a walk forward test. You can easily create...
Philip Raphael It is incredible! Thanks for sharing, Doctrading!
Reiner
9 years ago
Nicolas You should join and read the forum thread about this strategy. There are plenty of different...
Reiner Hi djtaktik and welcome, I have answered your question in the related Pathfinder forum beca...
danver34 is this version the definitive one or from the original one have there been modifications to...
Reiner
9 years ago
Nicolas Overfit on past history obviously. But it doesn't mean that it would still underperformed in...
Francesco78 Thank you for the clarifications Nicolas, I am more aware of the meaning of the backtesting ...
CanAny1Trade Hi all, could a simple indicator be made to mark the traditional Pit based ORB? I'm tryi...
Yannick Thanks for sharing. This strategy is flat for 11 years and winning afterwards. Don't you thi...
Doctrading Hello, As I usually say, strategies are exposed to be improved :) So yes, I think there mu...
Lior Green Doesn't work for me. Set values “compra” and “venta” to be shown as HISTOGRAM

Top