MTF - Box Trading StrategyMultiTime Frame - Box Trading Strategies (MTF-BT))
How does it work ? The code uses dynamic levels and crossovers on higher time frames to identify trade calls.
Model 1 (Default) Uses a low risk model and Model 2 (Optional) Uses an aggressive model
How to Deploy / Use
As part of the Indicator there are a few choices the user can opt for
Box Resolution - The resolution of the higher time frame for analysis , typically set at 90 , can be customized by the users.
Use Long Strategy 1 - This would add long trades based on Model1 Algorithm for the users
Use Short Strategy 1 - This would add short trades based on Model1 Algorithm for the users
Use Long Strategy 2 - This would add long trades based on Model2 Algorithm for the users
Use Short Strategy 2 - This would add short trades based on Model2 Algorithm for the users
Check Range Val Validate the width of the channel on higher timeframe and trade only when the channel is wider than the value provided ,
The value of 0.14 is determined using series of back test across various assets
Use Stop Loss : Flag to check if Stop Loss should be done by the strategy
Stop Loss Limit : Stop Loss in Absolute terms
Use Profit Booking : Flag to check if Profit Booking should be done by the strategy
Stop Loss Limit : Profit Target in Absolute terms
Do Intraday Exit :Flag to check if trade should be taken as an Intraday only
Exit Window : Session time during which the trade should be closed , like 15:00 - 15:30 for NSE , 22:30 - 23:00 for MCX etc ,
it should be wide enough to accommodate the resolution the use has on the screen
Visual Checks - The user could manually validate the back test results on various assets they would like to use this strategy on before putting it live.
Usage/Markets : Index Trading / Equities and also well with Commodities and Currencies
Time Frame : works well between 3 and 30 , keep the Box resolution to at least 45 for 3/5 mins TF and you could move upto 180 (3 hrs ) for a 30 mins TF.
Strategy Settings Used/Assumed : All of this values are provided in the Properties Tab of the Indicator Settings
and the users can customize it to suit the broker or the product they are charting it against
Initial Capital : 100 000
Order Size : 10 Quantities for Equities , you may change it to 1 lot for Future contracts based on capital deployed
Commission : is set at 0.05%
Slippage : 20 ticks
Recalculate Option : After the Order is filled is selected by default
Disclaimer : There could be scenarios when the breakout/breakdown candle is rejected , especially when it is long one
so it is always recommended to have a confirmation candle that open-closes above the breakout candle / open-closes below the breakdown candle
If you like it and find it useful or if you find a defect or bug , Please let us know in the comments .. that would encouraging !! for us to develop it further
Thank you and have a beautiful and Profitable trading session !
How to get access
Please click on the link / email in the signature or send me a private message to get access
Feedback
Please click on the link/email in the signature or send me a private message for suggestions/feedbacks
Intraday
MTF HTMultiTime Frame - HT ( Harmonic Trades)
How does it work ? The code uses two two models built on the theory of Harmonics to determine trade calls.
Model 1 (Default) Uses a low risk model and Model 2 (Optional) Uses an aggressive model
How to Deploy / Use
As part of the Indicator there are 1 Choices that the user can opt for
Box Resolution - The resolution of the checks , typically set at 60 , can be customized by the users.
Use Model 2 - This would add trades based on Model 2 Algorithm for the users
The Plot level display in three colored lines that are plotted by the code.
Black: Low end of the setup / Stop Loss
Red : Entry Point for the Setup
Teal: Target Point for the setup
Visual Checks - The user could manually initiate the trade at the colored lines mentioned above are placed and the trade is that same direction ,
The system would only initiate the trade when the appropriate harmonic pattern is identified
Usage/Markets : Index Trading / Equities and also well with Commodities and Currencies
Time Frame : works well between 3 and 30 , keep the Box resolution to at least 45 for 3 mins TF and you could move upto 120 (2 hrs ) for a 30 mins TF.
Strategy Settings Used/Assumed : All of this values are provided in the Properties Tab of the Indicator Settings
and the users can customize it to suit the broker or the product they are charting it against
Initial Capital : 200 000
Order Size : 1 Lot for Model 1 , and If you are optionally selecting Model 2 : 1 more lot would be used as and when applicable
Commission : is set at 0.025%
Slippage : 100 ticks
Recalculate Option : After the Order is filled is selected by default
Disclaimer : There could be scenarios when the breakout/breakdown candle is rejected , especially when it is long one
so it is always recommended to have a confirmation candle that open-closes above the breakout candle / open-closes below the breakdown candle
If you like it and find it useful or if you find a defect or bug , Please let us know in the comments .. that would encouraging !! for us to develop it further
Thank you and have a beautiful and Profitable trading session !
TradeSense Breakout Strategy v1TradeSense is a Renko brick breakout trading system for short-term or intraday trade. It is also a trend following strategy using a confluence of multiple MA's to spot the underlying trend. Exit and Stop Loss is based on dynamic ATR to predict possible target based on ticker's real time volatility.
So far this has been back-tested on major cyrptos, and the same concept is applicable to other asset types. It is more suitable for lower timeframes (such as the 30m, 15m, and 5m) though you may try adjusting the parameters for higher timeframes.
Feel free to backtest it and comment below!
Optimum parameters:
BTCUSD-15m
- Noise Filter: 1
- ATRLength : 15
- SL coefficient : 2.0
- TP coefficient : 1.5
ETHUSD-15m
- Noise Filter: 7
- ATRLength : 16
- SL coefficient : 2.0
- TP coefficient : 1.5
MACD Bull Crossover and RSI Oversold 5 Candles Ago-Long StrategyHello everyone, I've been having a great time perfecting this strategy for a few weeks now. I finally feel like it's time to release it to the public and share what I have been working on.
This strategy only enters a long trade when the MACD crosses over the signal line and the RSI was oversold looking back 5 candles ago. The logic behind this is to wait for RSI to enter the oversold territory, and then when the market starts to recovery the MACD will crossover telling us the sell off is over.
This strategy will close once these 2 conditions are met.
1. MACD Histogram is above 0 and MACD crosses under the signal line.
2. RSI was overbought 5 previous candles ago.
In the strategies settings, you'll be able to enable visual stop-loss and profit levels and change those levels to what you like, enable up to 5 EMA'S,
ADDONS That Affect Strategy:
* Enable visual stop-loss and profit levels as soon as a buy signal is triggered.
* Modify stop-loss and profit levels.
* Modify RSI oversold and RSI overbought levels.
* Modify MACD Fast and Slow moving average.
ADDONS That Do Not Affect Strategy:
* Enable up to 5 EMA's. (This will not affect strategy, and is the only purpose is for people who like following EMA's.)
Thank you for taking the time to try my strategy. I hope you have the best success. I will be making a short strategy, and alerts for this strategy soon. Follow me for updates!
FTSMA - Trend is your frendThis my new solid strategy: if you belive that "TREND IS YOUR FRIEND" this is for you!
I have tested with many pairs and at many timeframes and have profit with just minor changes in settings.
I suggest to use it for intraday trading .
VERY IMPORTANT NOTE: this is a trend following strategy, so the target is to stay in the trade as much as possible. If your trading style is more focused on scalping and/or pullbaks, this strategy is not for you.
This strategy uses moving averages applied to Fourier waves for forecasting trend direction.
How strategy works:
- Buy when fast MA is above mid MA and price is above slow MA, which acts as a trend indicator.
- Sell when fast MA is below mid MA and price is below slow MA, which acts as a trend indicator.
Strategy uses a lot of pyramiding orders because when you are in a flat market phase it will close 1 or 2 orders with a loss, but when a big trend starts, it will have profit in a lot of orders.
So, if you analize carefully the strategy results, you will note that "Percent Profitable" is very low (30% in this case) because strategy opened a lot of orders also in flat markets with small losses, BUT "Avg # bars in winning trades" is very high and overall Profit is very high: when a big trend starts, orders are kept open for long time generating big profits.
Thanks to all pinescripters mentioned in the code for their snippets.
I have also a study with alerts. Next improvement (only to whom is interested to this script and follows me): study with alerts on multiple tickers all at one. Leave a comment if you want to have access to study.
HOW TO USE STRATEGY AND STUDY TOGHETER:
1- Add to chart the strategy first, so your workspace will be as clean as possible.
2- Open the Strategy Tester tab at footer of the page.
3- Modify settings to get best results (Profit, Profit Factor, Drawdown).
4- Add study with alerts to your chart with same setting of strategy.
I WILL PROVIDE A DETAILED QUICK INSTALLATION GUIDE WITH THE STUDY!
Please use comment section for any feedback or contact me if you need support.
Strategy - Bobo PAPATRHi I've revamped this bot mentioned in the linked idea to make it work with v4 of pine. In doing so there are some very significant changes to how it works. The main one is that it no longer uses traditional daily pivot calculations to calculate the bands. It creates a more dynamic intraday set of pivot points based on recent price action rather than yesterday's ohlc. As published, the bot is tuned for a 15 min time frame. But it actually works well on lower time frames you just need to adjust the lookback periods in settings a bit to re tune it. It's also tuned to ES really but will need tweaking for a different instrument at the very least.
The basic concept is recent price action is used to calculate a 'middle' around which red and green bands are located. Their position or width is largely determined by recent volatility. The middle line is again calculated from recent price action. The three lines from that form a tradeable range with green at the top and red at the bottom. The strategy is simple enough, it shorts as it sinks from outside red, and longs when rising above green. The basic principle being that once you enter that range you have a high probability of hitting the middle before you hit your stop loss. So the basic principle is you are trying to capture the inherent ranginess of liquid indices like S&P 500. That back and forth movement that happens. The bot is capturing this by fading extremes of a recent range but the problem with that is you'dd get murdered in a strong trend. To mitigate that there is a trend calculation running in the background the will prevent trading against firm trends mostly. So the bot should trade mostly in rangy conditions because that is what it is trying to do.
Bot will close issue close signals automatically upon crossing the middle, it also will close automatically at predefined stops or limits. These values are denominated in market mintick values. For example the CFD SPX500 has a mintick of 0.1. Therefore a stop value of 100 will equate to 10 points on the index. If trading the same market via ES1! the mintick value is different - 0.25. So in this case a value of 40 is required to set the stop at 10 points.
Anyway shout if you have questions. Hope it's useful.
TVC:SPX OANDA:SPX500USD
Strategy - Bobo Intraday Swing Bot with filtersThis is an adapted version of my swing bot with additional filters that mean it works quite well on lower timeframes like 1min, 5 mins as long as you adjust the setting accordingly (reduce pivot timescale, band width)
Entry conditions are filtered by an invisible trend calculation running in the background so the bot doesn't repeatedly try and fail to fade a strong trend. It has just about everything you should need for basic use, stop losses and targets, automatically close trade at pivot.
I get good results on rangey instruments like major indices such as SPX / ES that kind of thing. Make sure you understand the minmum tick value of an index so the stop setting on the bot work properly
Hope it's useful!
Cyatophilum Intraday Breakouts [BACKTEST]Private indicator. Access can be unlocked by purchasing a subscription on my website which link is in my profile signature.
Here is the backtest version of the Triple Screen Strategy
Recap of the strategy:
The goal of this indicator is to be able to automate and backtest the strategy, all while staying on a single chart and without repainting.
Features:
Market Tide MACD configuration
Market Wave choice between 3 oscillator: Elder Force Index, Stochastic and William Percent Range
Automated Long and Short entries alerts
Integrated Trailing Stop Loss system fully configurable with automated exit alerts
Integrated Trailing Take profit system fully configurable with automated exit alerts
Indicator samples
Backtest
Strategy time period can be choosen in the parameters of the indicator.
Be aware that the chart is limited to 10 000 candles of the current timeframe for the backtest calculation.
Default initial capital: 10 000$
Default order size: 100% of equity
Default commission fees: 0.1% per transaction
Backtest results below.
Alerts
Entry Long: Triggers on green long labels.
Take Profit Long: Triggers on the "TAKE PROFIT" green flag if the long target is reached.
Stop Loss Long: Triggers on the "STOP LOSS" or "TSSL" label if the stop loss line has been crossed.
Exit Long: Triggers on either of Take Profit Long or Stop loss long.
Entry Short: Triggers on red short labels.
Take Profit Short: Triggers on the "TAKE PROFIT" green flag if the short target is reached.
Stop Loss Short: Triggers on the "STOP LOSS" or "TSSL" label if the stop loss line has been crossed.
Exit Short: Triggers on either of Take Profit Short or Stop Loss Short.
You can get access to this indicator by purchasing a subscription using the link below.
Thanks for reading!
All Instrument Swing Trader with Pyramids, DCA and Leverage
Introduction
This is my most advanced Pine 4 script so far. It combines my range trader algorithms with my trend following pyramids all on a single interval. This script includes my beta tested DCA feature along with simulated leverage and buying power calculations. It has a twin study with several alerts. The features in this script allow you to experiment with different risk strategies and evaluate the approximate impact on your account capital. The script is flexible enough to run on instruments from different markets and at various bar intervals. This strategy can be run in three different modes: long, short and bidirectional. The bidirectional mode has two split modes (Ping Pong and BiDir). It also generates a summary report label with information not available in the TradingView Performance report such as Rate Of Return Standard Deviation and other Sharpe Ratio input values. Notable features include the following:
- Swing Trading Paradigm
- Uni or Bidirectional trading modes
- Calculation presets for Crypto, Stocks and Forex
- Conditional Minimum Profit
- Hard stop loss field
- Two types of DCA (Positive and Negative)
- Discretionary Pyramid levels with threshold adjustment and limiter
- Consecutive loss counter with preset and label
- Reentry loss limiter and trade entry caution fields
- Simulated Leverage and margin call warning label (approximation only)
- Buying power report labels (approximation only)
- Rate Of Return report with input values for Sharpe Ratio, Sortino and others
- Summary report label with real-time status indicators
- Trend follow bias modes (Its still range trading)
- Six anti-chop settings
- Single interval strategy to reduce repaint occurrence
This is a swing trading strategy so the behavior of this script is to buy on weakness and sell on strength. As such trade orders are placed in a counter direction to price pressure. What you will see on the chart is a short position on peaks and a long position on valleys. Just to be clear, the range as well as trends are merely illusions as the chart only receives prices. However, this script attempts to calculate pivot points from the price stream. Rising pivots are shorts and falling pivots are longs. I refer to pivots as a vertex in this script which adds structural components to the chart formation (point, sides and a base). When trading in “Ping Pong” mode long and short positions are intermingled continuously as long as there exists a detectable vertex. Unfortunately, this can work against your backtest profitability on long duration trends where prices continue in a single direction without pullback. I have designed various features in the script to compensate for this event. A well configured script should perform in a range bound market and minimize losses in a trend. For a range trader the trend is most certainly not your friend. I also have a trend following version of this script for those not interested in trading the range.
This script makes use of the TradingView pyramid feature accessible from the properties tab. Additional trades can be placed in the draw-down space increasing the position size and thereby increasing the profit or loss when the position finally closes. Each individual add on trade increases its order size as a multiple of its pyramid level. This makes it easy to comply with NFA FIFO Rule 2-43(b) if the trades are executed here in America. The inputs dialog box contains various settings to adjust where the add on trades show up, under what circumstances and how frequent if at all. Please be advised that pyramiding is an advanced feature and can wipe out your account capital if your not careful. You can use the “Performance Bond Leverage” feature to stress test your account capital with varying pyramid levels during the backtest. Use modest settings with realistic capital until you discover what you think you can handle. See the“Performance Bond Leverage” description for more information.
In addition to pyramiding this script employs DCA which enables users to experiment with loss recovery techniques. This is another advanced feature which can increase the order size on new trades in response to stopped out or winning streak trades. The script keeps track of debt incurred from losing trades. When the debt is recovered the order size returns to the base amount specified in the TV properties tab. The inputs for this feature include a limiter to prevent your account from depleting capital during runaway markets. The main difference between DCA and pyramids is that this implementation of DCA applies to new trades while pyramids affect open positions. DCA is a popular feature in crypto trading but can leave you with large “bags” if your not careful. In other markets, especially margin trading, you’ll need a well funded account and much experience.
To be sure pyramiding and dollar cost averaging is as close to gambling as you can get in respectable trading exchanges. However, if you are looking to compete in a Forex contest or want to add excitement to your trading life style those features could find a place in your strategies. Although your backtest may show spectacular gains don’t expect your live trading account to do the same. Every backtest has some measure to data mining bias. Please remember that.
This script is equipped with a consecutive loss counter. A limit field is provided in the report section of the input dialog box. This is a whole number value that, when specified, will generate a label on the chart when consecutive losses exceed the threshold. Every stop hit beyond this limit will be reported on a version 4 label above the bar where the stop is hit. Use the location of the labels along with the summary report tally to improve the adaptability of system. Don’t simply fit the chart. A good trading system should adapt to ever changing market conditions. On the study version the consecutive loss limit can be used to halt live trading on the broker side (managed manually).
This script can simulate leverage applied to your account capital. Basically, you want to know if the account capital you specified in the properties tab is sufficient to trade this script with the order size, pyramid and DCA parameters needed. TradingView does not halt trading when the account capital is depleted nor do you receive notification of such an event. Input the leverage you intend to trade with and simulate the stress on your account capital. When the check box labeled “Report Margin Call” is enabled a marker will plot on the chart at the location where the threshold was breached. Additionally, the Summary Report will indicated such a breach has occurred during the backtest. Please note that the margin calculation uses a performance bond contract model which is the same type of leverage applied to Forex accounts. This is not the same leverage as stock margin accounts since shares are not actually borrowed. It is also not applicable to futures contracts since we do not calculate maintenance margin. Also note that the account margin and buying power are calculated using the U.S. Dollar as a funding currency. Margin rules across the globe vary considerably so use this feature as an approximation. The “Report Margin Call” plot only appears on negative buying power which is well beyond the NFA enforced margin closeout price. Vary the order size and account capital and activate the buying power plot to get as close as you can to the desired margin call threshold. Also keep in mind that rollover fees, commissions, spreads, etc affect the margin call in actual live trading. This feature does not include any of those costs.
Inputs
The script input dialog box is divided into five sections. The last section, Section 5, contains all of the script reporting options. Notable reporting options are the inputs which provide support for calculating actual Sharpe Ratios and other risk / performance metrics. The TradingView performance report does not produce a scalable Sharpe Ratio which is unfortunate considering the limited data supplied to the backtest. Three report fields made available in this section are intended to enable users to measure the performance of this script using various industry standard risk metrics. In particular, The Sharpe Ratio, Sortino Ratio, Alpha Calculation, Beta Calculation, R-Squared and Monthly Standard Deviation. The following fields are dedicated to this effort:
– ROR Sample Period - Integer number which specifies the rate of return period. This number is a component of the Sharpe Ratio and determines the number of sample periods divisible in the chart data. The number specified here is the length of the period measured in bar intervals. Since the quantity of TradingView historical data is limited this number should reflect the scalar value applied to your Sharpe calculation. When the checkbox “Report Period ROR” is enabled red boxes plot on the dates corresponding to the ROR sample period. The red boxes display information useful in calculating various risk and performance models. Ongoing buying power is included in the period report which is especially useful in assessing the DCA stress on account capital. Important: When the “ROR Sample Period” is specified the script computes the ROR mean value and displays the result in the summary report label on the live end of the chart. Use this number to calculate the historical standard deviation of period returns.
– Return Mean Value - This is the ROR mean value which is displayed in the summary report field “ROR Mean”. Enter the value shown in the summary report here in order to calculate the standard deviation of returns. Once calculated the result is displayed in the summary report field “Standard Dev”. Please note that ROR and standard deviation are calculated on the quote currency of the chart and not the account currency. If you intend to calculate risk metrics based on other denominated returns use the period calculations in a spreadsheet. Important: Do not change the account denomination on the properties tab simply to force a dollar calculation. It will alter the backtest itself since the minimum profit, stop-loss and other variables are always measured in the quote currency of the chart.
– Report Period ROR - This checkbox is used to display the ROR period report which plots a red label above the bars corresponding to the ROR sample period. The sample period is defined by the value entered into the “ROR Sample Period” field. This checkbox only determines if the period labels plot on the chart. It does not enable or disable the ROR calculation itself. Please see input description“ROR Sample Period” for a detailed description of this feature.
Design
This script uses twelve indicators on a single time frame. The original trading algorithms are a port from a much larger program on another trading platform. I’ve converted some of the statistical functions to use standard indicators available on TradingView. The setups make heavy use of the Hull Moving Average in conjunction with EMAs that form the Bill Williams Alligator as described in his book “New Trading Dimensions” Chapter 3. Lag between the Hull and the EMAs form the basis of the entry and exit points. The vertices are calculated using one of five featured indicators. Each indicator is actually a composite of calculations which produce a distinct mean. This mathematical distinction enables the script to be useful on various instruments which belong to entirely different markets. In other words, at least one of these indicators should be able generate pivots on an arbitrarily selected instrument. Try each one to find the best fit.
The entire script is around 2200 lines of Pine code which pushes the limits of what can be created on this platform given the TradingView maximums for: local scopes, run-time duration and compile time. This script incorporates code from both my range trader and trend following published programs. Both have been in development for nearly two years and have been in beta test for the last several months. During the beta test of the range trading script it was discovered that by widening the stop and delaying the entry, add on trading opportunities appeared on the chart. I determined that by sacrificing a few minor features code space could be made available for pyramiding capability in the range trader. The module has been through several refactoring passes and makes extensive use of ternary statements. As such, It takes a full three minutes to compile after adding it to a chart. Please wait for the hovering dots to disappear before attempting to bring up the input dialog box. For the most part the same configuration settings for the range script can be applied to this script.
Inputs to the script use cone centric measurements in effort to avoid exposing adjustments to the various internal indicators. The goal was to keep the inputs relevant to the actual trade entry and exit locations as opposed to a series of MA input values and the like. As a result the strategy exposes over 70 inputs grouped into long or short sections. Inputs are available for the usual minimum profit and stop-loss as well as safeguards, trade frequency, pyramids, DCA, modes, presets, reports and lots of calibrations. The inputs are numerous, I know. Unfortunately, at this time, TradingView does not offer any other method to get data in the script. The usual initialization files such as cnf, cfg, ini, json and xml files are currently unsupported.
I have several example configuration settings that I use for my own trading. They include cryptocurrencies and forex instruments on various time frames.
Indicator Repainting and Anomalies
Indicator repainting is an industry wide problem which mainly occurs when you mix backtest data with real-time data. It doesn't matter which platform you use some form of this condition will manifest itself on your chart over time. The critical aspect being whether live trades on your broker’s account continue to match your TradingView study.
Based on my experience with Pine, most of the problems stem from TradingView’s implementation of multiple interval access. Whereas most platforms provide a separate bar series for each interval requested, the Pine language interleaves higher time frames with the primary chart interval. The problem is exacerbated by allowing a look-ahead parameter to the Security function. The goal of my repaint prevention is simply to ensure that my signal trading bias remains consistent between the strategy, study and broker. That being said this is what I’ve done address this issue in this script:
1. This script uses only 1 time frame. The chart interval.
2. Every entry and exit condition is evaluated on closed bars only.
3. No security functions are called to avoid a look-ahead possibility.
4. Every contributing factor specified in the TradingView wiki regarding this issue has been addressed.
5. Entry and exit setups are not reliant on crossover conditions.
6. I’ve run a 10 minute chart live for a week and compared it to the same chart periodically reloaded. The two charts were highly correlated with no instances of completely opposite real-time signals. I do have to say that there were differences in the location of some trades between the backtest and the study. But, I think mostly those differences are attributable to trading off closed bars in the study and the use of strategy functions in the backtest.
The study does indeed bring up the TV warning dialog. The only reason for this is because the script uses an EMA indicator which according to TradingView is due to “peculiarities of the algorithm”. I use the EMA for the Bill Williams Alligator so there is no way to remove it.
One issue that comes up when comparing the strategy with the study is that the strategy trades show on the chart one bar later than the study. This problem is due to the fact that “strategy.entry()” and “strategy_exit()” do not execute on the same bar called. The study, on the other hand, has no such limitation since there are no position routines.
Please be aware that the data source matters. Cryptocurrency has no central tick repository so each exchange supplies TradingView its feed. Even though it is the same symbol the quality of the data and subsequently the bars that are supplied to the chart varies with the exchange. This script will absolutely produce different results on different data feeds of the same symbol. Be sure to backtest this script on the same data you intend to receive alerts for. Any example settings I share with you will always have the exchange name used to generate the test results.
Usage
The following steps provide a very brief set of instructions that will get you started but will most certainly not produce the best backtest. A trading system that you are willing to risk your hard earned capital will require a well crafted configuration that involves time, expertise and clearly defined goals. As previously mentioned, I have several example configs that I use for my own trading that I can share with you. To get hands on experience in setting up your own symbol from scratch please follow the steps below.
The input dialog box contains over 70 inputs separated into five sections. Each section is identified as such with a makeshift separator input. There are three main areas that must to be configured: long side, short side and settings that apply to both. The rest of the inputs apply to pyramids, DCA, reporting and calibrations. The following steps address these three main areas only. You will need to get your backtest in the black before moving on to the more advanced features.
Step 1. Setup the Base currency and order size in the properties tab.
Step 2. Select the calculation presets in the Instrument Type field.
Step 3. Select “No Trade” in the Trading Mode field.
Step 4. Select the Histogram indicator from Section 2. You will be experimenting with different ones so it doesn’t matter which one you try first.
Step 5. Turn on Show Markers in Section 2.
Step 6. Go to the chart and checkout where the markers show up. Blue is up and red is down. Long trades show up along the red markers and short trades on the blue.
Step 7. Make adjustments to “Base To Vertex” and “Vertex To Base” net change and roc in Section 3. Use these fields to move the markers to where you want trades to be.
Step 8. Try a different indicator from Section 2 and repeat Step 7 until you find the best match for this instrument on this interval. This step is complete when the Vertex settings and indicator combination produce the most favorable results.
Step 9. Go to Section 3 and enable “Apply Red Base To Base Margin”.
Step 10. Go to Section 4 and enable “Apply Blue Base To Base Margin”.
Step 11. Go to Section 2 and adjust “Minimum Base To Base Blue” and “Minimum Base To Base Red”. Observe the chart and note where the markers move relative to each other. Markers further apart will produce less trades but will reduce cutoffs in “Ping Pong” mode.
Step 12. Return to Section 3 and 4 and turn off “Base To Base Margin” which was enabled in steps 9 and 10.
Step 13. Turn off Show Markers in Section 2.
Step 14. Put in your Minimum Profit and Stop Loss in the first section. This is in pips or currency basis points (chart right side scale). Percentage is not currently supported. This is a fixed value minimum profit and stop loss. Also note that the profit is taken as a conditional exit on a market order not a fixed limit. The actual profit taken will almost always be greater than the amount specified (due to the exit condition). The stop loss, on the other hand, is indeed a hard number which is executed by the TradingView broker simulator when the threshold is breached. On the study version, the stop is executed at the close of the bar.
Step 15. Return to step 3 and select a Trading Mode (Long, Short, BiDir, Ping Pong). If you are planning to trade bidirectionally its best to configure long first then short. Combine them with “BiDir” or “Ping Pong” after setting up both sides of the trade individually. The difference between “BiDir” and “Ping Pong” is that “Ping Pong” uses position reversal and can cut off opposing trades less than the specified minimum profit. As a result “Ping Pong” mode produces the greatest number of trades.
Step 16. Take a look at the chart. Trades should be showing along the markers plotted earlier.
Step 17. Make adjustments to the Vertex fields in Section 2 until the TradingView performance report is showing a profit. This includes the “Minimum Base To Base” fields. If a profit cannot be achieved move on to Step 18. Other adjustments may make a crucial difference.
Step 18. Improve the backtest profitability by adjusting the “Entry Net Change” and “Entry ROC” in Section 3 and 4.
Step 19. Enable the “Mandatory Snap” checkbox in Section 3 and 4 and adjust the “Snap Candle Delta” and “Snap Fractal Delta” in Section 2. This should reduce some chop producing unprofitable reversals.
Step 20. Increase the distance between opposing trades by adding an “Interleave Delta” in Sections 3 and 4. This is a floating point value which starts at 0.01 and typically does not exceed 2.0.
Step 21. Increase the distance between opposing trades even further by adding a “Decay Minimum Span” in Sections 3 and 4. This is an absolute value specified in the symbol’s quote currency (right side scale of the chart). This value is similar to the minimum profit and stop loss fields in Section 1.
Step 22. Improve the backtest profitability by adjusting the “Sparse Delta” in Section 3 and 4.
Step 23. Improve the backtest profitability by adjusting the “Chase Delta” in Section 3 and 4.
Step 24. Improve the backtest profitability by adjusting the “Adherence Delta” in Section 3 and 4. This field requires the “Adhere to Rising Trend” checkbox to be enabled.
Step 25. Try each checkbox in Section 3 and 4. See if it improves the backtest profitability. The “Caution Lackluster” checkbox only works when “Caution Mode” is enabled.
Step 26. Enable the reporting conditions in Section 5. Look for long runs of consecutive losses or high debt sequences. These are indications that your trading system cannot withstand sudden changes in market sentiment.
Step 27. Examine the chart and see that trades are being placed in accordance with your desired trading goals. This is an important step. If your desired model requires multiple trades per day then you should be seeing hundreds of trades on the chart. Alternatively, you may be looking to trade fewer steep peaks and deep valleys in which case you should see trades at major turning points. Don’t simply settle for what the backtest serves you. Work your configuration until the system aligns with your desired model. Try changing indicators and even intervals if you cannot reach your simulation goals. Generally speaking, the histogram and Candle indicators produce the most trades. The Macro indicator captures the tallest peaks and valleys.
Step 28. Apply the backtest settings to the study version and perform forward testing.
This script is open for beta testing. After successful beta test it will become a commercial application available by subscription only. I’ve invested quite a lot of time and effort into making this the best possible signal generator for all of the instruments I intend to trade. I certainly welcome any suggestions for improvements. Thank you all in advance.
One final note. I'm not a fan of having the Performance Overview (blue wedge) automatically show up at the end of the publish page since it could be misleading. On the EUR/USD backtest showing here I used a minimum profit of 65 pips, a stop of 120 pips, the candle indicator and a 5 pyramid max value. Also Mark Pyramid Levels (blue triangles) are enabled along with a 720 ROR Sample Period (red labels).
Full Range Trading Strategy with DCA - Crypto, Forex, Stocks
Introduction
This is a Pine 4 range trading strategy. It has a twin study with several alerts. The design intent is to produce a commercial grade signal generator that can be adapted to any symbol and interval. Ideally, the script is reliable enough to be the basis of an automated trading system web-hooked to a server with API access to crypto, forex and stock brokerages. The strategy can be run in three different modes: long, short and bidirectional.
As a range trading strategy, the behavior of the script is to buy on weakness and sell on strength. As such trade orders are placed in a counter direction to price pressure. What you will see on the chart is a short position on peaks and a long position on valleys. Just to be clear, the range as well as trends are merely illusions as the chart only receives prices. However, this script attempts to calculate pivot points from the price stream. Rising pivots are shorts and falling pivots are longs. I refer to pivots as a vertex in this script which adds structural components to the chart formation. When trading in “Ping Pong” mode long and short positions are intermingled continuously as long as there exists a detectable vertex. Unfortunately, this can work against your backtest profitability on long duration trends where prices continue in a single direction without pullback. I have designed various features in the script to compensate for this event. A well configured script should perform in a range bound market and minimize losses in a trend. I also have a trend following version of this script for those not interested in trading the range. Please be aware these are two types of traders. You should know who you are.
This script employs a DCA feature which enables users to experiment with loss recovery techniques. This is an advanced feature which can increase the order size on new trades in response to stopped out or winning streak trades. The script keeps track of debt incurred from losing trades. When the debt is recovered the order size returns to the base amount specified in the TV properties tab. The inputs for this feature include a limiter to prevent your account from depleting capital during runaway markets. This implementation of DCA does not use pyramid levels. Only the order size on subsequent new trades are affected. Pyramids on the other hand increase the size of open positions. If you are interested in seeing pyramids in action please see the trend version of this script which features both DCA and pyramids. While DCA is a popular feature in crypto trading, it can make you a “bag” holder if your not careful. In other markets, especially margin trading, you’ll need a well funded account and much trading experience to manage this feature safely.
Consecutive loss limit can be set to report a breach of the threshold value. Every stop hit beyond this limit will be reported on a version 4 label above the bar where the stop is hit. Use the location of the labels along with the summary report tally to improve the adaptability of system. Don’t simply fit the chart. A good trading system should adapt to ever changing market conditions. On the study version the consecutive loss limit can be used to halt live trading on the broker side (managed manually).
Design
This script uses twelve indicators on a single time frame. The original trading algorithms are a port from a much larger program on another trading platform. I’ve converted some of the statistical functions to use standard indicators available on TradingView. The setups make heavy use of the Hull Moving Average in conjunction with EMAs that form the Bill Williams Alligator as described in his book “New Trading Dimensions” Chapter 3. Lag between the Hull and the EMAs form the basis of the entry and exit points. The vertices are calculated using one of five featured indicators. Each indicator is actually a composite of calculations which produce a distinct mean. This mathematical distinction enables the script to be useful on various instruments which belong to entirely different markets. In other words, at least one of these indicators should be able generate pivots on an arbitrarily selected instrument. Try each one to find the best fit.
The entire script is around 1800 lines of Pine code which is the maximum incidental size given the TradingView limits: local scopes, run-time duration and compile time. I’ve been working on this script for nearly two years and have tested it on various instruments stocks, forex and crypto. It performs well on higher liquidity markets that have at least a year of historical data. Although the script can be implemented on any interval, it has been optimized for small time frames down to 5 minutes. The 10 minute BTC/USD produces around 500 trades in 2 ½ months. The 1 hour BTC/USD produces around 1300 trades in 1 ½ years. Originally, this script contained both range trading and trend following logic but had to be broken into separate scripts due to the aforementioned limitations.
Inputs to the script use cone centric measurements in effort to avoid exposing adjustments to the various internal indicators. The goal was to keep the inputs relevant to the actual trade entry and exit locations as opposed to a series of MA input values and the like. As a result the strategy exposes over 50 inputs grouped into long or short sections. Inputs are available for the usual minimum profit and stop-loss as well as safeguards, trade frequency, DCA, modes, presets, reports and lots of calibrations. The inputs are numerous, I’m aware. Unfortunately, at this time, TradingView does not offer any other method to get data in the script. The usual initialization files such as cnf, cfg, ini, json and xml files are currently unsupported.
Example configurations for various instruments along with a detailed PDF user manual is available.
Indicator Repainting And Anomalies
Indicator repainting is an industry wide problem which mainly occurs when you mix backtest data with real-time data. It doesn't matter which platform you use some form of this condition will manifest itself on your chart over time. The critical aspect being whether live trades on your broker’s account continue to match your TradingView study.
Tackling this repainting issue has been a major project goal of this script. Based on my experience with Pine, most of the problems stem from TradingView’s implementation of multiple interval access. Whereas most platform provide a separate bar series for each interval requested, the Pine language interleaves higher time frames with the primary chart interval. The problem is exacerbated by allowing a look-ahead parameter to the Security function. The goal of my repaint prevention is simply to ensure that my signal trading bias remains consistent between the strategy, study and broker. That being said this is what I’ve done address this issue in this script:
1. This script uses only 1 time frame. The chart interval.
2. Every entry and exit condition is evaluated on closed bars only.
3. No security functions are called to avoid a look-ahead possibility.
4. Every contributing factor specified in the TradingView wiki regarding this issue has been addressed.
5. I’ve run a 10 minute chart live for a week and compared it to the same chart periodically reloaded. The two charts were highly correlated with no instances of completely opposite real-time signals.
The study does indeed bring up the TV warning dialog. The only reason for this is because the script uses an EMA indicator which according to TradingView is due to “peculiarities of the algorithm”.
One issue that comes up when comparing the strategy with the study is that the strategy trades show on the chart one bar later than the study. This problem is due to the fact that “strategy.entry()” and “strategy_exit()” do not execute on the same bar called. The study, on the other hand, has no such limitation since there are no position routines.
Please be aware that the data source matters. Cryptocurrency has no central tick repository so each exchange supplies TradingView its feed. Even though it is the same symbol the quality of the data and subsequently the bars that are supplied to the chart varies with the exchange. This script will absolutely produce different results on different data feeds of the same symbol. Be sure to backtest this script on the same data you intend to receive alerts for. Any example settings I share with you will always have the exchange name used to generate the test results.
Usage
The following steps provide a very brief set of instructions that will get you started but will most certainly not produce the best backtest. A trading system that you are willing to risk your hard earned capital will require a well crafted configuration that involves time, expertise and clearly defined goals. As previously mentioned, I have several example configs that I use for my own trading that I can share with you along with a PDF which describes each input in detail. To get hands on experience in setting up your own symbol from scratch please follow the steps below.
The input dialog box contains over 50 inputs separated into five sections. Each section is identified as such with a makeshift separator input. There are three main areas that must to be configured: long side, short side and settings that apply to both. The rest of the inputs apply to DCA, reporting and calibrations. The following steps address these three main areas only. You will need to get your backtest in the black before moving on to the more advanced features.
Step 1. Setup the Base currency and order size in the properties tab.
Step 2. Select the calculation presets in the Instrument Type field.
Step 3. Select “No Trade” in the Trading Mode field.
Step 4. Select the Histogram indicator from Section 2. You will be experimenting with different ones so it doesn’t matter which one you try first.
Step 5. Turn on Show Markers in Section 2.
Step 6. Go to the chart and checkout where the markers show up. Blue is up and red is down. Long trades show up along the red markers and short trades on the blue.
Step 7. Make adjustments to “Base To Vertex” and “Vertex To Base” net change and roc in Section 3. Use these fields to move the markers to where you want trades to be.
Step 8. Try a different indicator from Section 2 and repeat Step 7 until you find the best match for this instrument on this interval. This step is complete when the Vertex settings and indicator combination produce the most favorable results.
Step 9. Go to Section 3 and enable “Apply Red Base To Base Margin”.
Step 10. Go to Section 4 and enable “Apply Blue Base To Base Margin”.
Step 11. Go to Section 2 and adjust “Minimum Base To Base Blue” and “Minimum Base To Base Red”. Observe the chart and note where the markers move relative to each other. Markers further apart will produce less trades but will reduce cutoffs in “Ping Pong” mode.
Step 12. Return to Section 3 and 4 and turn off “Base To Base Margin” which was enabled in steps 9 and 10.
Step 13. Turn off Show Markers in Section 2.
Step 14. Put in your Minimum Profit and Stop Loss in the first section. This is in pips or currency basis points (chart right side scale). Percentage is not currently supported. This is a fixed value minimum profit and stop loss. Also note that the profit is taken as a conditional exit on a market order not a fixed limit. The actual profit taken will almost always be greater than the amount specified. The stop loss, on the other hand, is indeed a hard number which is executed by the TradingView broker simulator when the threshold is breached. On the study version, the stop is executed at the close of the bar.
Step 15. Return to step 3 and select a Trading Mode (Long, Short, BiDir, Ping Pong). If you are planning to trade bidirectionally its best to configure long first then short. Combine them with “BiDir” or “Ping Pong” after setting up both sides of the trade individually. The difference between “BiDir” and “Ping Pong” is that “Ping Pong” uses position reversal and can cut off opposing trades less than the specified minimum profit. As a result “Ping Pong” mode produces the greatest number of trades.
Step 16. Take a look at the chart. Trades should be showing along the markers plotted earlier.
Step 17. Make adjustments to the Vertex fields in Section 2 until the TradingView performance report is showing a profit. This includes the “Minimum Base To Base” fields. If a profit cannot be achieved move on to Step 18.
Step 18. Improve the backtest profitability by adjusting the “Long Entry Net Change” and “Long Entry ROC” in Section 3.
Step 19. Improve the backtest profitability by adjusting the “Short Entry Net Change” and “Short Entry ROC” in Section 4.
Step 20. Improve the backtest profitability by adjusting the “Sparse Long Delta” in Section 3.
Step 21. Improve the backtest profitability by adjusting the “Chase Long Delta” in Section 3.
Step 22. Improve the backtest profitability by adjusting the “Long Adherence Delta” in Section 3. This field requires the “Adhere to Rising Trend” checkbox to be enabled.
Step 23. Try each checkbox in Section 3 and see if it improves the backtest profitability. The “Caution Lackluster Longs” checkbox only works when “Long Caution Mode” is enabled.
Step 24. Improve the backtest profitability by adjusting the “Sparse Short Delta” in Section 4.
Step 25. Improve the backtest profitability by adjusting the “Chase Short Delta” in Section 4.
Step 26. Improve the backtest profitability by adjusting the “Short Adherence Delta” in Section 4. This field requires the “Adhere to Falling Trend” checkbox to be enabled.
Step 27. Try each checkbox in Section 4 and see if it improves the backtest profitability. The “Caution Lackluster Shorts” checkbox only works when “Short Caution Mode” is enabled.
Step 28. Enable the reporting conditions in Section 5. Look for long runs of consecutive losses or high debt sequences. These are indications that your trading system cannot withstand sudden changes in market sentiment.
Step 29. Examine the chart and see that trades are being placed in accordance with your desired trading goals. This is an important step. If your desired model requires multiple trades per day then you should be seeing hundreds of trades on the chart. Alternatively, you may be looking to trade fewer steep peaks and deep valleys in which case you should see trades at major turning points. Don’t simply settle for what the backtest serves you. Work your configuration until the system aligns with your desired model. Try changing indicators and even intervals if you cannot reach your simulation goals. Generally speaking, the histogram and Candle indicators produce the most trades. The Macro indicator captures the tallest peaks and valleys.
Step 30. Apply the backtest settings to the study version and perform forward testing.
This script is open for beta testing. After successful beta test it will become a commercial application available by subscription only. I’ve invested quite a lot of time and effort into making this the best possible signal generator for all of the instruments I intend to trade. I certainly welcome any suggestions for improvements. Thank you all in advance.
Total Trend Follow Strategy with Pyramid and DCA
Introduction
This is a Pine 4 trend following strategy. It has a twin study with several alerts. The design intent is to produce a commercial grade signal generator that can be adapted to any symbol and interval. Ideally, the script is reliable enough to be the basis of an automated trading system web-hooked to a server with API access to crypto, forex and stock brokerages. The strategy can be run in three different modes: long, short and bidirectional.
As a trend following strategy, the behavior of the script is to buy on strength and sell on weakness. As such the trade orders maintain its directional bias according to price pressure. What you will see on the chart is long positions on the left side of the mountain and short on the right. Long and short positions are not intermingled as long as there exists a detectable trend. This is extremely beneficial feature in long running bull or bear markets. The script uses multiple setups to avoid the situation where you got in on the trend, took a small profit but couldn’t get back in because the logic is waiting for a pullback or some other intricate condition.
Deep draw-downs are a characteristic of trend following systems and this system is no different. However, this script makes use of the TradingView pyramid feature accessible from the properties tab. Additional trades can be placed in the draw-down space increasing the position size and thereby increasing the profit or loss when the position finally closes. Each individual add on trade increases its order size as a multiple of its pyramid level. This makes it easy to comply with NFA FIFO Rule 2-43(b) if the trades are executed here in America. The inputs dialog box contains various settings to adjust where the add on trades show up, under what circumstances and how frequent if at all. Please be advised that pyramiding is an advanced feature and can wipe out your account capital if your not careful. During the backtest use modest setting with realistic capital until you discover what you think you can handle.
In addition to pyramiding this script employs DCA which enables users to experiment with loss recovery techniques. This is another advanced feature which can increase the order size on new trades in response to stopped out or winning streak trades. The script keeps track of debt incurred from losing trades. When the debt is recovered the order size returns to the base amount specified in the TV properties tab. The inputs for this feature include a limiter to prevent your account from depleting capital during runaway markets. The main difference between DCA and pyramids is that this implementation of DCA applies to new trades while pyramids affect open positions. DCA is a popular feature in crypto trading but can leave you with large “bags” if your not careful. In other markets, especially margin trading, you’ll need a well funded account and much experience.
Consecutive loss limit can be set to report a breach of the threshold value. Every stop hit beyond this limit will be reported on a version 4 label above the bar where the stop is hit. Use the location of the labels along with the summary report tally to improve the adaptability of system. Don’t simply fit the chart. A good trading system should adapt to ever changing market conditions. On the study version the consecutive loss limit can be used to halt live trading on the broker side (Managed manually).
Design
This script uses nine indicators on two time frames. The chart (primary) interval and one higher time frame which is based on the primary. The higher time frame identifies the trend for which the primary will trade. I’ve tried to keep the higher time frame around five times greater than the primary. The original trading algorithms are a port from a much larger program on another trading platform. I’ve converted some of the statistical functions to use standard indicators available on TradingView. The setups make heavy use of the Hull Moving Average in conjunction with EMAs that form the Bill Williams Alligator as described in his book “New Trading Dimensions” Chapter 3. Lag between the Hull and the EMAs form the basis of the entry and exit points. The alligator itself is used to identify the trend main body.
The entire script is around 1700 lines of Pine code which is the maximum incidental size given the TradingView limits: local scopes, run-time duration and compile time. I’ve been working on this script for over a year and have tested it on various instruments stocks, forex and crypto. It performs well on higher liquidity markets that have at least a year of historical data. Though it can be configured to work on any interval between 5 minutes and 1 day, trend trading is generally a longer term paradigm. For day trading the 10 to 15 minute interval will allow you to catch momentum breakouts. For intraweek trades 30 minutes to 1 hour should give you a trade every other a day. Four hours and above are for seasoned deep pocket traders. Originally, this script contained both range trading and trend following logic but had to be broken into separate scripts due to the aforementioned limitations.
Inputs to the script use cone centric measurements in effort to avoid exposing adjustments to the various internal indicators. The goal was to keep the inputs relevant to the actual trade entry and exit locations as opposed to a series of MA input values and the like. As a result the strategy exposes over 50 inputs grouped into long or short sections. Inputs are available for the usual minimum profit and stop-loss as well as safeguards, trade frequency, DCA, modes, presets, reports and lots of calibrations. The inputs are numerous, I’m aware. Unfortunately, at this time, TradingView does not offer any other method to get data in the script. The usual initialization files such as cnf, cfg, ini, json and xml files are currently unsupported.
Example configurations for various instruments along with a detailed PDF user manual is available.
Indicator Repainting And Anomalies
Indicator repainting is an industry wide problem which mainly occurs when you mix backtest data with real-time data. It doesn't matter which platform you use some form of this condition will manifest itself on your chart over time. The critical aspect being whether live trades on your broker’s account continue to match your TradingView study. Since this trading system is featured as two separate scripts, indicator repainting is addressed in the study version. The strategy (this script) is intended to be used on historical data to determine the appropriate trading inputs to apply in the study. As such, the higher time frame of this strategy will indeed repaint. Please do not attempt to trade from the strategy. Please see the study version for more information.
One issue that comes up when comparing the strategy with the study is that the strategy trades show on the chart one bar later than the study. This problem is due to the fact that “strategy.entry()” and “strategy_exit()” do not execute on the same bar called. The study, on the other hand, has no such limitation since there are no position routines. However, alerts that are subsequently fired off when triggered in the study are dispatched from the TradingView servers one bar later from the study plot. Therefore the alert you actually receive on your cell phone matches the strategy plot but is one bar later than the study plot. A lot can happen in four hours if you are trading off a 240 bar.
Please be aware that the data source matters. Cryptocurrency has no central tick repository so each exchange supplies TradingView its feed. Even though it is the same symbol the quality of the data and subsequently the bars that are supplied to the chart varies with the exchange. This script will absolutely produce different results on different data feeds of the same symbol. Be sure to backtest this script on the same data you intend to receive alerts for. Any example settings I share with you will always have the exchange name used to generate the test results.
Usage
The following steps provide a very brief set of instructions that will get you started but will most certainly not produce the best backtest. A trading system that you are willing to risk your hard earned capital will require a well crafted configuration that involves time, expertise and clearly defined goals. As previously mentioned, I have several example configs that I use for my own trading that I can share with you along with a PDF which describes each input in detail. To get hands on experience in setting up your own symbol from scratch please follow the steps below.
The input dialog box contains over 50 inputs separated into seven sections. Each section is identified as such with a makeshift separator input. There are three main areas that must to be configured: long side, short side and settings that apply to both. The rest of the inputs apply to pyramids, DCA, reporting and calibrations. The following steps address these three main areas only. You will need to get your backtest in the black before moving on to the more advanced features
Step 1. Setup the Base currency and order size in the properties tab.
Step 2. Select the calculation presets in the Instrument Type field.
Step 3. Select “No Trade” in the Trading Mode field.
Step 4. Select the Histogram indicator from section 3. You will be experimenting with different ones so it doesn’t matter which one you try first.
Step 5. Turn on Show Markers in Section 3.
Step 6. Go to the chart and checkout where the markers show up. Blue is up and red is down. Long trades show up along the blue markers and short trades on the red.
Step 7. Make adjustments to Base To Vertex and Vertex To Base net change and roc in section 3. Use these fields to move the markers to where you want trades to be. Blue is long and red is short.
Step 8. Try a different indicator from section 3 and repeat Step 7 until you find the best match for this instrument on this interval. This step is complete when the Vertex settings and indicator combination produce the most favorable results.
Step 9. Turn off Show Markers in Section 3.
Step 10. Enable the Symmetrical and Deviation calculation models at the top of section 5 and 6 (Symmetrical, Deviation).
Step 11. Put in your Minimum Profit and Stop Loss in the first section. This is in pips or currency basis points (chart right side scale)
Step 12. Return to step 3 and select a Trading Mode (Long, Short, BiDir, Flip Flop). If you are planning to trade bidirectionally its best to configure long first then short. Combine them with BiDir or Flip Flop after setting up both sides of the trade individually.
Step 13. Trades should be showing on the chart.
Step 14. Make adjustments to the Vertex fields in section 3 until the TradingView performance report is showing a profit.
Step 15. Change indicators and repeat step 14. Pick the best indicator.
Step 16. Use the check boxes in sections 5 and 6 to improve the performance of each side.
Step 17. Try adding the Correlation calculation model to either side. This model can sometimes produce a negative result but can be improved by enabling “Adhere To Markers” or “Narrow Correlation Scope” in the sections 5 and 6.
Step 18. Enable the reporting conditions in section 7. Look for long runs of consecutive losses or high debt sequences. These are indications that your trading system cannot withstand sudden changes in market sentiment.
Step 19. Examine the chart and see that trades are being placed in accordance with your desired trading model.
Step 20. Apply the backtest settings to the study version and perform forward testing.
This script is open for beta testing. After successful beta test it will become a commercial application available by subscription only. I’ve invested quite a lot of time and effort into making this the best possible signal generator for all of the instruments I intend to trade. I certainly welcome any suggestions for improvements. Thank you all in advance.
QuantCat Intraday Strategy (15M)QuantCat Intraday Strategy
This strategy is designed to be used on the 15 minute time frame, on liquid x/btc pairs and BTC/USD.
It works by having 2 moving averages, automatic stop loss calculation, and taking positions on MA crosses and MA zone bounces for confirmation.
Stoploss is so crucial to minimise any damage from huge unexpected candles, the strategies can just be used for entries as well, you don't have to stick to the exact formula- of the long and short system, but this by itself is profitable.
The system nets positive results on
-BTC/USD
-ETH/BTC
-LTC/BTC
-XRP/BTC
There is a small element of trend filtering also for the MA's, but I found adding it in actually hindered performance when testing and training the strategies unless it was using a loose value.
You can get live alerts for this strategy and speak to our developers by joining our server on discord! (Link in signature)
PivotIntradayStrategy@scorpiomanojFRMThis is an intraday trading strategy using Floor Pivots for BankNifty.
This strategy overlays on the charts with wide variety of drawing floor pivots and previous day levels.
VERY IMPORTANT :
1) LONGS AND SHORTS TO BE TAKEN IN 5 MIN CHART. 15 MIN CHART IS DISPLAYED BECAUSE TV DOESNT ALLOW TO PUBLISH WITH TF LESS THAN 15 MIN.
2) BACKTEST RESULTS ASSUME EXITS AT DAY CLOSE ONLY AND NOT BASED ON ANY OTHER CONDITIONS. HENCE ONCE LONG OR SHORT INITIATED IT IS SUGGESTED TO EXIT USING TRAILING STOP OR YOUR OWN RISK APPETITE. EVEN DAY CLOSE INTRADAY EXITS OFFERS A FAIRLY GOOD RESULT WITH ABOVE AVERAGE SUCCESS RATE AND PROFIT FACTOR IN EXCESS OF 1.75.
3) STRATEGY IS BASED ON COMBINATION OF PATTERNS INVOLVING DAILY PIVOTS AND PREV DAY LEVELS THAT IS FOUND TO REPEAT IN BANKNIFTY.
THE DETAILS OF THE STRATEGY IS CONFIDENTIAL.
4) THIS WILL BE AVAILABLE PUBLICLY ONLY FOR A LIMITED PERIOD. THIS LIMITED PERIOD AVAILABILITY IS TO TEST THE RESULTS AMONG VARIOUS PARTICIPANTS INORDER TO SEE THE CONSISTENCY.
YOU CAN REACH ME AT MY TWITTER ID scorpiomanojfrm or my email scorpiomanojfrm AT gmail DOT com
The Puria MethodTraders who work on this system argue that the Forex Strategy “The Puria Method” can make a 50 points profit a day :) FX:EURUSD )
Naresh - iJPASIMPORTANT NOTE
This strategy has been developed as a professional service. It was published only or testing and verification by the customer. As such, access cannot be granted to anyone else. Sorry about that!
Other open source scripts are available on the BacktestRookies profile.
Intra-day Japanese Candlestick Price Action Strategy
An intraday strategy which focuses on analyzing price action of the opening 3 bars to make trading decisions.
Once certain criteria are met, entry and exit targets are set and left until they are hit else we reset and start again on a new day.
Intraday Buy/Sell signals for CrudeoilHi Everyone,
This is higly tuned intraday Buy/Signal generator for Crudeoil. It works on any time frames below 30 mins. But, the best setting is 15 mins.
How to use:
1. Just, apply this strategy to your crudeoil WTI instrument
2. Set your time frame to 15 mins
3. Buy the instrument whenever buy signal generates / Sell the intrument whenever buy singal generates
4. Strategy itself has 0.5% stop loss generating signals. But, create stop loss of 0.5% after buying/selling the instrument
5. Finally, whenever close signals triggers, just close the trade.
Note: Please try with only one lot at the beginning. If everything goes well after testing, mulitple lot can be used.
Disclaimer:
This strategy is for testing purpose only. Any profit/loss to the user's capitla is subject to market risk. And, the creator of this script is no where responsible.
GBPUSD INTRADAY 12/16utcHi guys,
this is my new super easy strategy, on GBPUSD 1 hour chart it gives its best.
12-16utc means: at 12 utc watch the chart to see if to open a position (long or short). If a position has been opened close at 16utc.
So basically you have only to rememeber to check the chart at 12 utc. You can set a SL @50pips, and a TP @100pips, but the strategy runs without them, so feel free to use them or not.
This strategy has an "easy view mode": you can choose wether use it on mobile chart to have a better view. Using "easy view" you will see only the bars in trading session from 12 to 16 utc. Otherwise you can have the reguar chart.
Subscribe for only 20€/month and
Enjoy your Wallet!
Tari
SampleInvitePublish - V1
This strategy is designed for trading stocks and crypto currencies on the long side.
It uses three different timeframes to determine the most profitable entry prices (Day, 4 hour and chart interval).
The strategy employs ten different setups to accommodate both range trading and trend following markets.
The system contains sophisticated algorithms that scale to varies chart intervals.
Tailored to perform best between 4 hours to as low as 10 minutes.
The entire system consists of three tools: HullbusterScope, HullbusterBacktest and HullbusterSignal.
Hullbuster scope is used to obtain configuration information about the market instrument which will be applied to the HullbusterBacktest.
Commit an iterative approach to the backtest tool until the simulated results match your entry and exit expectations .
Apply the HullbusterSignal to the chart and use the same backtest configuration to setup actual trading alerts.
Oscillator Strategy for Scalping (BITMEX Swaps btc + eth)This is short selling strategy for BITMEX's XBTUSD and ETHUSD swaps scalping.
Made specifically for 3M XBTUSD and 3M-5M ETHUSD timeframe trading.
Not gonna open all the details, but it works mostly on bear divergences and moving averages.
On premium it shows 10000 bars back on 3minute timeframe and over that period(3 weeks aprox) XBTUSD had 28 trades and ETHUSD had 25(+17 on 5M timeframe) trades with that strategy.
How to trade it and setups that i use for manual trading:
1: You can use it to confirm your bias. Sell signal appears + price tries to retake previous resistance = most likely it will fail.
2. Sell signal after wick up suggests that you are likely to get filled at the top.
Your main target should be this moving average. Basically sell signal appears at resistance/near one and moving average represents current line of support. So when you enter short you should be eyeing this MA as your exit/target. Yes, there is a good possibility that support wount hold and this is a bear market we talking about BUT it is 3M bot oriented trading strategy, dont forget about and dont hold for too long to find yourself with price lending on MA and jumping from it.
This strategy does not have a defined stop, rather it suggests you to calculate it based on entry (provided) and target (provided).
Here is what i usually do to calculate my risks. My reward is a move to line of support, my stop is usually 1R, winrate is much higher than 50% so i feel good about it. Entry either at sell signal or at wick. Wicks not always get runned, but they provide incredible r/r setups.
Free trial for 36 hours for this one.
MKZ HiLo Intraday Systemthe systems is based on Swings/Waves made by the stock.
It doesn't use any indicators, its purely based on price action.
2pm_3pm_4pm GBPUSD TARI PRIVATE 2.0Hi guys!
This is a new version of my strategies 2pm_3pm_4pm. UTC+2 ROME
The only change is that the position has to be closes, if doesn't hit the sl or the tp, at 2pm, and you will have only to check for signals at 3pm or 4 pm.
Chek more @
Subscribe to get access!
Enjoy your wallet!
Tari.