Schaff Trend Cycle

Schaff Trend Cycle

This Schaff Trend Cycle code is an attempt to recode the same indicator as the one in the platform to be user with simplified creation to build automatic trading strategy through ProOrder or stock screener with ProScreener. Enjoy. Idea and final code come from this discussion: https://www.prorealcode.com/topic/why-cant-use-or-call-some-indicator/

How to use it:

The Schaff Trend Cycle (STC) indicator, invented by Dough Schaff, measures the overbought and oversold market conditions. This is an improved version of the traditional MACD indicator widely used by traders.
The STC works by detecting trends, uses exponential moving averages (EMAs), but includes a cycle to include trends in currency sequences.

The STC indicator combines the MACD with a slow stochastic indicator and provides an early signal to recognize trends.

The STC indicator oscillates between 0 and 100.
Less than 20 readings are considered oversold. Over 80 readings are considered overbought.

 

 

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?

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

  1. oraclus • 08/03/2017 #

    Merci il lui ressemble bcp

  2. juanj • 08/03/2017 #

    Think this is something we can experiment with in the ‘universal’ strategy along with the Bollinger and RSI2.

    https://www.prorealcode.com/prorealtime-trading-strategies/universal-strategy/

  3. ggolfet • 08/03/2017 #

    Hello Francesco,
    thanks for the code. Now I can do backtests on this indicator. I’m testing a weekly strategy and noticed that the parameters which fit most stock indexes do not work with volatile stock markets or commodities. Does every market have a different “cycle”, so you need to fit the indicator to every market (risking overfitting)?
    For weekly chart I use:
    TCLen = 25
    MA1 = 30
    MA2 = 60.

avatar
Register or

Likes

avatar avatar avatar avatar avatar avatar
Related users ' posts
hartgeld Bonjour Nicolas, j'ai réussi. J'ai intégré une troisième unité de temps, tout va bien! Je va...
Jan Wind Good evening Nicolas, thanks for the indicator. How are the short and medium trend peri...
Nicolas I don't know, that code is a 1:1 translation from another platform.
Juanjo Hola, Buscando un sistema valido para operar el squeeze, he reprogramado el indicador para ...
mauro1966 BRAVO....
Gianluca THANK YOU!!!!!
Polnet Solucionado, gracias
Jan Wind Hallo Tac Bolsa, Thanks a lot for your coding above. As I am personally not very charm...
TAC Bolsa Thank you, Jan Any modification is good reference if it helps us win in the market.
luxrun Ok, thank you
robertogozzi I just discovered that ProOrder (for automated strategies) does not evaluate the expression ...
robertogozzi //Ti = ((close > Cy) * Tt) OR (((close Cy) THEN Ti = Tt ELSE Ti = -Tt ENDIF
PastaPesto Hello Roberto! Thank you for this indicator. I thought I would try it out in a strategy, bu...
robertogozzi I just realized that there's a line that shouldn't be there. It's line 5, please remove it,...
robertogozzi I just discovered that ProOrder (for automated strategies) does not evaluate the expression ...
luxrun bellissimo lavoro, Roberto, grazie!
robertogozzi I just discovered that ProOrder (for automated strategies) does not evaluate the expression ...
Akram Hi Roberto the WPZO is the bounded oscillator by percentage like the SHO Here is the artic...
juanj DId some tests using MACD validations on higher timeframes using MTF functionality and unfor...
FREDNC Hi Francesco I tried with :
FREDNC adx[14]>adxmin and adx[14] > adxr[14] and adx[14]>adxmin and adx[14] DIminus[3](clo...
jpm380 Merci pour ce super indicateur. Comment puis-je mettre une alerte dès changement dès croisem...
bala Hi Kris, I have imported the screen. I don't see any instrument loaded under this screen....
Kris75 Hi Bala, you need first to install ZeroLagMACDWeek indicator and then add on it the diverg...
berga Hi, thank you very much for this very useful screener. I would like to get another very clos...
skysoldier hello, thank you for this code, I was wondering if it is compatible with thinkorswim at all?
Nicolas No, but you can ask for private coding job at our programming services.
supertiti Hola Ale Can we have this same code from Nicolas's code in smoothed heikin Ashi? Sorry...
ALE Ok, We can discuss in the topic "3D Candlesticks TOPIC" Write me more details
tradingthelife Hi friends, any help with a screener for this indicator? Best regards.
franciscojbritop Hola tradingthelife, has tenido suerte encontrando un screener para este indicador? He estad...
franciscojbritop Hola Jose7674, Utilizas algun screener para encontrar candidatos que esten mostrando estas M...
Nicolas Thank you Xusto. Thank you a lot for your contribution :) Since your code is a Pathfinder'...
Xusto Hello, Fully Agree, I will update it with your advice. Btw Can would you like share you co...
Niklas johansson hägglund do you now if it's possible to use this strategy with this code in tradingview also?
AGTrader Interesante, muy visual Doc. Felicidades!!!
Andraxx simplemente impresionante Dom...te sigo en youtube. Me ha gustado tu canal. Gracias por comp...
Toto le Heros Thanks Nicolas. I read somewhere that in the calculation, we should round the value of the A...
Nicolas aADX = round(adx[10])
JanWd Hey Doctrading, I tried your code, optimising the A and V and the RSI period, see below. ...
Glen Marquis This will work as there is plenty of room for the Target before the Stop, yet the Stop would...
magicT I did a copy and paste of this code and PRT 10.3 returns a synthax mistake: OneTradePerD...
juanj Definitely, need to code this into an automated strategy.
Marc Boliart dear nicolas, tyvm for your indicators and strategies, i have this following error when i ch...
Nicolas Your picture is too small, but for sure the problem is about the fact you are still using v1...

Top