OPEN-SOURCE SCRIPT

Kitchen [ilovealgotrading]

Atualizado
  • OVERVIEW:

Kitchen is a strategy that aims to trade in the direction of the trend by using supertrend and stochRsi data by calculating at different time values.

  • IMPLEMENTATION DETAILS – SETTINGS:

First of all, let's understand the supertrend and stocrsi indicators.
How do you read and use Super Trend for trading ?
The price is often going upwards when it breaks the super trend line while keeping its position above the indication level.
When the market is in a bullish trend, the indicator becomes green. The indicator level will act as trendline support in such a scenario. The color of the indicator changes to red to indicate a negative trend once the price crosses the support line. The price uses the super trend level as a trendline resistance during a bearish move.
https://www.tradingview.com/x/4LdxDIKu/
In our strategy, if our 1-hour and 4-hour supertrend lines show the up or down train in the same direction at the same time, we can assume that a train is forming here.

Why do I use the time of 1 hour and 4 hours ?
When I did a backtest from the past to the present, I discovered that the most accurate and consistent time zones are the 1 hour and 4 hour time zones.
*By the way we can change our short term timeframe(1H) and long term timeframe(4H) from settings panel.

How do you read and use the Stoch-RSI Indicator?
This indicator analyzes price dynamics automatically to detect overbought and oversold locations.
The indicator includes:
- The primary line, which typically has values between 0 and 100;
- Two dynamic levels for overbought and oversold conditions.
https://www.tradingview.com/x/uGblM4SC/
IF our stoch-rsi indicator value has fallen below our lower boundary line, the oversold event has been observed in the price, if our stoch-rsi value breaks up our bottom line after becoming oversold, we think that the price will start the recovery phase.(The case is also true for the opposite.)
However, this does not always apply and we need additional approvals, Therefore, our 1H and 4H supertrrend indicator provides us with additional confirmation.

  • Buy Condition:

https://www.tradingview.com/x/rmRSzdQp/
Our 1H(short term) and 4H(long term) supertrrend indicator, has given the buy signal(green line and yellow line), and if our stochrsi indicator has broken our oversold line up on the past 15 bars, the buy signal is formed here.

  • Sell Condition:

https://www.tradingview.com/x/yHhuKsh1/
Our 1H(short term) and 4H(long term) supertrrend indicator, has given the sell signal(red line and orange line), and if our stochrsi indicator has broken our overbuy line down on the past 15 bars, the sell signal is formed here.

  • Stop Loss or Take Profit Conditions:
  • Exit Long Senerio:

https://www.tradingview.com/x/SjGPUUPs/
All conditions are completed, the buy signal has arrived and we have entered a LONG trade, the 1-hour supertrend line follows the price rise(yellow line), if the price breaks below the 1-hour super trend line and a sell condition occurs for 1H timeframe for supertrend indcator, LONG trade will exit here.

  • Exit Short Senerio:

https://www.tradingview.com/x/AjXhgQ3s/
All conditions are completed, the Sell signal has arrived and we have entered a SHORT trade, the 1-hour supertrend line follows the price down(orange line), if the price breaks up the 1-hour super trend line and a buy condition occurs for 1H timeframe for supertrend indcator, SHORT trade will exit here.

  • What can you change in the settings panel?

https://www.tradingview.com/x/No1ESPFc/
1-We can set Start and End date for backtest and future alarms
2-We can set ATR length and Factor for supertrend indicator
3-We can set our short term and long term timeframe value
4-We can set StochRsi Up and Low limit to confirm buy and sell conditions
5-We can set stochrsi retroactive approval length
6-We can set stochrsi values or the length
7-We can set Dollar cost for per position
8- We can choose the direction of our positions, we can set only LONG, only SHORT or both directions.
9-IF you want to place automatic buy and sell orders with this strategy, you can paste your codes into the Long open-close or Short open-close message sections.

For example
IF you write your alert window this code {{strategy.order.alert_message}}.
When trigger Long signal you will get dynamically what you pasted here for Long Open Message

  • ALSO:

Please do not open trades without properly managing your risk and psychology!!!

If you have any ideas what to add to my work to add more sources or make calculations cooler, suggest in DM .
Notas de Lançamento
Update for End_Time
educationalfreesignalsindicatorsMoving AveragesopensourcecodeRelative Strength Index (RSI)stockrsistrategysupertrend

Script de código aberto

No verdadeiro espírito do TradingView, o autor desse script o publicou como código aberto, para que os traders possam compreendê-lo e analisá-lo. Parabéns ao autor! Você pode usá-lo gratuitamente, mas a reutilização desse código em publicações é regida pelas Regras da Casa. Você pode favoritá-lo para usá-lo em um gráfico.

Quer usar esse script no gráfico?


I am an engineer who has been working in the topic of algorithmic trading for more than 5 years.By browsing our website , you can review and use many sample indicators that I have designed for you.
Também em:

Aviso legal