S&P 500 daily RSI(2) long short strategy

S&P 500 daily RSI(2) long short strategy

Hi all,

Have a look to this daily strategy on S&P 500. I guess many of you already know it, as it is made very famous by Larry Connors, I just added a bit of asymmetry between long and short, but the code is still extremely light, with only 2 parameters optimized and a stable performance of over 20 year!

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. maorai • 10/21/2017 #

    hi Francesco,
    the variables a and b are missing !!
    thanks for clarify it

  2. Francesco78 • 10/21/2017 #

    a = 10 b = 30, if you run the optimization this is what you will get

  3. Vonasi • 10/21/2017 #

    I’m a big fan of anything with Larry Connors on the SP500 with RSI[2]. I notice that your exit criteria are different for long and short positions. A long position needs a down candle to exit but the short positions exit on up or down candles. Can you explain any logical reasoning behind this or is it just something that seemed to work better?

  4. Francesco78 • 10/21/2017 #

    Hi Vonasi. The logic is based in the fact that the market has a bias to go up. This asymmetry allows long positions to have an “advantage” over short positions.

  5. Vonasi • 10/21/2017 #

    It seems that buy and hold outperforms this strategy. Removing the short side of the strategy (I’m not keen on shorting indices especially the SP500) results in close to buy and hold performance without the amount of time in the market and far less volatility in the equity curve. Not many trades though. Settings of 15 and 35 seem to be optimal for this.

  6. quietlife • 10/21/2017 #

    HI. My first post on PRC. I tied this on UKX I am limited with 2500 bars, but the results looked very good.

  7. Robin von Bauhn • 10/21/2017 #

    Nice strategy! Really like the stuff you are posting. Although the performance on the short side is quite bad when in raging bull markets. So try out my favourite filter; close > close[180] (or anywhere between 100-250) for longs and opposite for shorts. Greatly reduces drawdown 🙂

  8. Francesco78 • 10/21/2017 #

    hi Robin, thank you for yiur comment. Would you mind to post the exact modification to the code that you make? Id love to test it. have a great day.

  9. Robin von Bauhn • 10/21/2017 #

    Here you go! Would like to hear your feedback 🙂

    cl = RSI[2]100-a

    if cl and close > close[180] then
    buy 5 contracts at market
    endif

    if cs and close 100-(a+b) then
    sell at market
    endif

    if shortonmarket and RSI[2]<(a+b) then
    exitshort at market
    endif

  10. Francesco78 • 10/21/2017 #

    Sorry there might be few typos, pls send the full code.
    Thank you

  11. Robin von Bauhn • 10/21/2017 #

    Oh, it’s “cs” that’s missing. I don’t have the code right now but it’s the exact same conditions as in your code above so you can copy it from there. But as you might see I made the sides more symmetrical and removed “close < open" as condition for long exit

  12. Manuel9z • 10/21/2017 #

    Hola Francesco, gracias por tu estrategia. Cuando intento activarla en ProOrder, no lo permite, indica este mensaje: Deben aplicarse los siguientes cambios antes de enviar el código a ProOrder:
    – Reemplace las variables. Para lanzar esta estrategia en trading automático, suprima las variables de la ventana de programación en la sección BroBacktest y reemplácelas por valores específicos en el código de su sistema de trading.
    Puedes ayudarme en que he de hacer. Muchas gracias

  13. Manuel9z • 10/21/2017 #

    ok, sorry, I’ve already configured it with a = 10 b = 30 thanks Francesco for your post

  14. snucke • 10/21/2017 #

    Hello Francesco!

    when i replace a&b with 10&30 the results are not the same?

    how can i make this code applicable for live trading? cause i must remove the a&b with values

  15. Francesco78 • 10/21/2017 #

    @snucke the results are not the same because the pictures refers to a few years ago. I am not sure how the strategy will look now with the same parameters.

    • sfl • 233 days ago #

      still working, using with filters like :

      trendFilterUp=close>average[190](close)
      trendFilterDw=close<average[190](close)

      same parameters 10,30

  16. snucke • 10/21/2017 #

    @Francesco78 i mean the results differ when i test on my own.

    so im curious of what the parameters a&b are based on?

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar avatar

+6 more likes

Related users ' posts
Madrosat I Have not see a fully functioning automated strategy on your site?? Really have you???
juanj Hi Madrosat, why would it be on my site? I have developed it for my personal use and also to...
Madrosat ok I understood you are using prorealcode to hack the fish
imonix Have been trying this on demo since Monday before deciding whether to go live with it. Using...
Roberto Blázquez I'm sorry, I've tried it since November 2012 and it's bad results.
woktrade Superbe !
Vonasi An updated version with a bug fix can be found here: https://www.prorealcode.com/topic/dis...
snucke hey Vonasi is it possible you can help me get this indicator to show how much a market mo...
kbrooks323 Hello would someone be willing to release a scan code for this? that would be helpful as I s...
Nicolas You can do easily this screener by using the assisted creation tool. It would take you about...
kbrooks323 I just figured it out thanks!
Vinks_o_7 Vonasi you're a beast !!! ;-)))
pableitor Amazing indicator , you are pushing PRT to the limit! But looking at the scatter its not c...
Vinks_o_7 Thanks Doc !
Maxime Baudin Intresting, thank you!
Zigo
4 years ago
fifi743 Good morning, there is no mistake about the shorts c11=SMI[14,3,5](close)>-40
Zigo has to be c11=SMI[14,3,5] < -40 (indeed)
xar3 Thank you ;-) Zigo
Sapo Thank you very much. as always your indicators are extremely effective. kind regards Vonasi.
mitsu21 Hi, it looks nice. I'll try it tomorrow thank you for your share kind regards bruno
kj1988 Thank you Vonasi for sharing this indicator. Very useful as a comfirmation to the price act...
ggolfet Thanks Nicolas, I imported the itf file and solved the problem.
Hasardeur Hallo Nicolas, i tried to code the multi period heat map in combination with the Ehler’s ...
Nicolas Please open a new topic with the code in forum.
Marie-Eve Vergoz lorsque je copie les codes, le système me signale des erreurs à la ligne 12 et suivantes
Marie-Eve Vergoz sorry - tout est ok -
AlgoAlex
5 years ago
Marcot18 Alex ti sei superato
AlexF Esagerato!
jobswaps Sube como trazar lineas de tendencias a tantas barras
Frankiesc interesting indicator !! Thanks for sharing!!!
robertogozzi Thank you :)
phanz Hi ... what are the conditions for buy signal using this indicator? Tks
JJ Tec Hola Las condiciones de entrada / salida vienen en el libro de J. Carter Mastering the trad...
Pixeldd Ich bekomme beim einfügen des Indikators einen Fehler angezeigt. Was bitte muss ich genau än...
sir_i Bonjour à tous, Je suis nouveau sur le forum et sur la plateforme, pourriez-vous me dire com...
Nicolas Il faut simplement l'appliquer sur le prix.
sir_i Merci pour la réponse, je ne suis pas familier avec l'application de cette procédure simple,...
Nicolas Il s'agit d'un indicateur compatible avec PRT v11 uniquement. Pour éviter les erreurs de cop...
Sébi Intéressant. Merci pour ce partage Nicolas. L'indicateur ne considère pas les divergences ...
Nicolas ok, pour les divergences chacun voit midi à sa porte je dirai :) Vu qu'il n'y a pas de formu...
mcha merci bien et félicitations pour la réactivité avec laquelle il a été mis dans la bibliothèq...
soulintact Great indicator Nicolas, thanks!
cdc.andersson Hello, when trying to include this wonderful Dynamic RSI on my trading system i get the erro...
Rafyone Bonjour Nicolas et bonne année lol J'ai une erreur qui apparait concernant drawbarchart une...
Nicolas Je pense que tu n'utilises pas le bon éditeur de code, cette instruction est compatible uniq...
Exalaxe Hey, i just noticed you optimized this strategy. Could i see your new version, please?
Andrea.1981 sorry i add my code but it not enter why i dont know
Andrea.1981 this is code simply stop , and you can see another version for stop / Codice principale...
AntoGH how did you backtest it ?
PastaPesto @AntoGH , I dont know if you are asking me, but my backtest was made in an IS of 4 years bet...
Ridder @PastaPesto Do you still running this and how is the results? Thanks

Top