Conceptive Price Moving Average [CSM]The Conceptive Price Moving Average (CPMA) is a technical indicator designed to provide a more accurate moving average of the price by using the average of various price types, such as open, close, high, low, etc. The CPMA can help to smooth out the noise and provide a clearer picture of the overall trend by taking the average of the last 3 candles for each price type and then calculating the average of those averages.
To use the CPMA for generating buy/sell signals, you can look for crossovers of the CPMA and other commonly used moving averages, such as the 9-period EMA, 20-period EMA, 50-period EMA, 100-period EMA, and 200-period EMA, which are also plotted on the chart. When the CPMA crosses above a shorter-term moving average, such as the 9-period EMA or 20-period EMA, it can indicate a potential buy opportunity, while when the CPMA crosses below a shorter-term moving average, it can indicate a potential sell opportunity.
Based on my analysis of BankNifty and Nifty, I have found that the CPMA works best at a length of 21, showing good resistance and support for stocks. Therefore, I recommend using a length of 21 when using the CPMA for generating buy/sell signals.
Media mobile semplice (SMA)
Simple Moving Average Slope [AstrideUnicorn]The Simple Moving Average Slope indicator (SMAS) is a technical analysis tool designed to help traders detect the direction and strength of the current trend in the price of an asset. It is also a great tool for identifying sideways markets. The indicator plots the slope of a simple moving average (SMA) of the closing prices over a specified time period. The slope is normalized by dividing it by the standard deviation of the slope over a longer time period.
HOW TO USE
Traders can use the Simple Moving Average Slope indicator in various ways. One common way is to look for bullish or bearish signals. A bullish signal occurs when the normalized slope rises above a predetermined threshold, resulting in the indicator turning green, indicating an upward trend in the market. Conversely, a bearish signal is generated when the normalized slope falls below the negative value of the threshold, causing the indicator to turn red, signaling a downtrend in the market. When the normalized slope falls between the positive and negative threshold values, a neutral signal is generated, indicating that the market is moving sideways. This can help traders avoid false trend signals from other indicators and strategies that may occur when the market is in a sideways regime. Additionally, traders can use the Simple Moving Average Slope indicator in conjunction with other technical indicators to confirm the trend direction.
SETTINGS
Window - specifies the number of bars used to calculate the SMA slope. The default value is 20.
Threshold - specifies the threshold value used to generate the bullish and bearish signals. The default value is 0.6. Traders can adjust these settings based on their trading strategy and the asset being analyzed.
Display Trade Volume with MA Angle and Price VelocityThis Pine Script indicator is designed to provide traders with a visual representation of trade volume, moving average (MA) angle, and price velocity on a chart. The primary components of this indicator are:
Trade Volume: The indicator compares the current bar's trade volume with the average volume over a user-defined lookback period. The volume is displayed as either "Low" or "Trade" in a table, with red or green background color, respectively, to indicate whether it's below or above the average volume.
MA Angle: The indicator calculates the angle of the moving average (either Simple, Exponential, or Hull) over a user-defined length. A positive angle is shown in green, while a negative angle is shown in red. The angle is displayed in degrees in the table.
Price Velocity: This component calculates the velocity of price movement by comparing the difference between high and low prices over a user-defined lookback period. It then displays the velocity as either "Slow" or "Fast" in the table, with red or green background color, respectively, depending on whether it's below or above the average difference.
The indicator also includes alert conditions for high and low volume situations, notifying the trader when the current bar's volume is significantly higher or lower than the average volume.
Ignition Cha Cha ChaIgnition Cha Cha Cha (ICCC) is a 3 color coded moving average indicator which numerically quantify the angle of their trends. I have labeled them as fast, medium and slow. The trend colors are Green for bullish, Red for bearish and Grey for sideways. The sideways movement can be user defined for all 3 in the settings under Threshold. If you regard for example anything under 10º as sideways then place 10 in the corresponding threshold and any angle under 10º will give a grey moving average and a grey labeled text. I use this chart in several ways. If you don't want moving averages all over your Chartistic Masterpiece you can turn off the plots and leave the numeric angles which will give you an overview of the trend. Conversely if you want to make the ultimate trend chart you can setup a 4 chart layout, Weekly, Daily, 12 hour and 4 hour and add the indicator with 200/50/25 moving averages and look for confluence. I find the best way for this is turn off the candles and use the moving averages with the numeric labels. You also have the ability to turn off and on different aspects of the indicator so that there is good control over its look. Also I have given the indicator lots of Alert presets for all 3 of the moving averages so you can avoid demented screen-stairing. Please forgive the name, my mother made me do Ballroom dancing lessons as a kid.
Moving Average Trap Strategy by D. BrigagliaThis is a strategy that follows the 200 periods moving average and fades the cross of ma3, ma5 and ma8. It is designed for profiting by mean reversion while at the same time respecting long term trend. It is designed for long term trending markets such as stocks and stock indices.
In this backtest, the strategy shows the ability to beat the S&P500 index with an average slippage set to 2 ticks. The number of trades is good (350), the profit factor is acceptable (1.67). The drawdowns are also reduced compared to the underlying asset.
Nothing of my content is financial advice.
ADD 2This is a modification to the original ADD script by Tom1trader
I added the option to choose the timeframe, moving average type and length.
Note from the original script:
"This is the NYSE Advancers - decliners which the SPX pretty much follows. You can chart it like any index (ADD -NYSE $ADV MINUS $DECL) but I find it more useful in a separate panel with colors for direction.
The level gives an idea of days move (example: plus or minus 500 is not much movement through the session) but I follow the direction as when more stocks advance (green) or decline (red) the index tends to track it pretty closely.
On SPX , SPY and correlates - very useful for intra-day trading (Scalping or 0DTE option trades) but not for higher time frames at all. If you chart the ADD in a chart and compare 5 minute to daily you will see what I mean."
Mean Reversion and TrendfollowingTitle: Mean Reversion and Trendfollowing
Introduction:
This script presents a hybrid trading strategy that combines mean reversion and trend following techniques. The strategy aims to capitalize on short-term price corrections during a downtrend (mean reversion) as well as ride the momentum of a trending market (trend following). It uses a 200-period Simple Moving Average (SMA) and a 2-period Relative Strength Index (RSI) to generate buy and sell signals.
Key Features:
Combines mean reversion and trend following techniques
Utilizes 200-period SMA and 2-period RSI
Customizable starting date
Allows for enabling/disabling mean reversion or trend following modes
Adjustable position sizing for trend following and mean reversion
Script Description:
The script implements a trading strategy that combines mean reversion and trend following techniques. Users can enable or disable either of these techniques through the input options. The strategy uses a 200-period Simple Moving Average (SMA) and a 2-period Relative Strength Index (RSI) to generate buy and sell signals.
The mean reversion mode is active when the price is below the SMA200, while the trend following mode is active when the price is above the SMA200. The script generates buy signals when the RSI is below 20 (oversold) in mean reversion mode or when the price is above the SMA200 in trend following mode. The script generates sell signals when the RSI is above 80 (overbought) in mean reversion mode or when the price falls below 95% of the SMA200 in trend following mode.
Users can adjust the position sizing for both trend following and mean reversion modes using the input options.
To use this script on TradingView, follow these steps:
Open TradingView and load your preferred chart.
Click on the 'Pine Editor' tab located at the bottom of the screen.
Paste the provided script into the Pine Editor.
Click 'Add to Chart' to apply the strategy to your chart.
Please note that the past performance of any trading system or methodology is not necessarily indicative of future results. Always use proper risk management and consult a financial advisor before making any investment decisions.
------
The following is a summary of the underlying whitepaper (onlinelibrary.wiley.com) for this strategy:
This paper proposes a theory of securities market under- and overreactions based on two psychological biases: investor overconfidence about the precision of private information and biased self-attribution, which causes asymmetric shifts in investors' confidence as a function of their investment outcomes. The authors show that overconfidence implies negative long-lag autocorrelations, excess volatility, and public-event-based return predictability. Biased self-attribution adds positive short-lag autocorrelations (momentum), short-run earnings "drift," and negative correlation between future returns and long-term past stock market and accounting performance.
The paper explains that there is empirical evidence challenging the traditional view that securities are rationally priced to reflect all publicly available information. Some of these anomalies include event-based return predictability, short-term momentum, long-term reversal, high volatility of asset prices relative to fundamentals, and short-run post-earnings announcement stock price "drift."
The authors argue that investor overconfidence can lead to stock prices overreacting to private information signals and underreacting to public signals. This overreaction-correction pattern is consistent with long-run negative autocorrelation in stock returns, excess volatility, and further implications for volatility conditional on the type of signal. The market's tendency to over- or underreact to different types of information allows the authors to address the pattern that average announcement date returns in virtually all event studies are of the same sign as the average post-event abnormal returns.
Biased self-attribution implies short-run momentum and long-term reversals in security prices. The dynamic analysis based on biased self-attribution can also lead to a lag-dependent response to corporate events. Cash flow or earnings surprises at first tend to reinforce confidence, causing a same-direction average stock price trend. Later reversal of overreaction can lead to an opposing stock price trend.
The paper concludes by summarizing the findings, relating the analysis to the literature on exogenous noise trading, and discussing issues related to the survival of overconfident traders in financial markets.
Cycle Position TradingTitle: Cycle Position Trading Strategy v1.0
Description: Cycle Position Trading Strategy is a simple yet effective trading strategy based on a 200-day Simple Moving Average (SMA). Users can select between two modes, "Buy Uptrend" and "Buy Downtrend," to customize the strategy according to their trading preferences. The strategy allows users to set their own stop loss (SL) and take profit (TP) levels, providing more flexibility and control over their trades.
Features:
Choose between two trading modes: "Buy Uptrend" and "Buy Downtrend."
Customize your stop loss (SL) and take profit (TP) levels.
Clear visual representation of the 200-day Simple Moving Average (SMA) on the chart.
How to use:
Add the strategy to your chart by searching for "Cycle Position Trading Strategy" in the TradingView "Indicators & Strategies" section.
Configure the strategy settings according to your preferences:
Select the trading mode from the dropdown menu. "Buy Uptrend" will open long positions when the closing price is above the 200-day SMA. "Buy Downtrend" will open long positions when the closing price is below the 200-day SMA.
Set your desired stop loss (SL) and take profit (TP) levels. The default values are 0.9 (10% below the entry price) for the stop loss and 1.1 (10% above the entry price) for the take profit.
Monitor the chart for trade signals based on the chosen mode and settings. The strategy will enter and exit trades automatically based on the selected mode and the configured stop loss and take profit levels.
Analyze the performance of the strategy by checking the TradingView strategy performance summary or by viewing individual trades in the "Trades" list.
Disclaimer: This strategy is intended for educational and illustrative purposes only. Use it at your own risk. Past performance is not indicative of future results. Trading stocks, cryptocurrencies, or any other financial instrument involves significant risk and may result in the loss of capital.
Version: v1.0
Release date: 2023-03-25
Author: I11L
License: Mozilla Public License 2.0 (mozilla.org)
SB Multiple Moving Averages (Simple)This script contains 7 simple moving averages. You can use 1-7 moving averages on the chart. Also you can display in the table this moving averages. If the box on the chart is green , close price is above the moving average but if box is red, close price is below the moving average. And this feature is very useful because if you do not want to see the complex moving averages on the chart, you can just look the table and remove the averages on the chart.
Moving Average Lab - by InFinitoThe Moving Average Lab allows to create any possible combination of up to 3 given MAs. It is meant to help you find the perfect MA that fits your style, strategy and market type.
This script allows to average, weight, double and triple multiple types and lengths of Moving Averages
Currently supported MA types are:
SMA
EMA
VWMA
WMA
SMMA (RMA)
HMA
LSMA
DEMA
TEMA
Features:
- Double or Triple any type of Moving Average using the same logic used for calculating DEMAs and TEMAs:
In the following example you can see a normal, double and triple 200 VWMA
- Average 2 or 3 different types and lengths of Moving Average:
In the example you can see the average between a Double LSMA and a SMA
- Weight each MA manually:
The example shows the average of an HMA and a VWMA with the HMA having a weight of 2 and the VWMA having a weight of 1
- Average up to 3 personalized MAs:
The example shows the average of an EMA + a Double WMA + a Triple SMA with a 3:2:1 weighting
- Average different Moving Averages with different length each:
The example shows the average of an 800 SMA + a 400 VWMA + a 200 EMA
Simple_RSI+PA+DCA StrategyThis strategy is a result of a study to understand better the workings of functions, for loops and the use of lines to visualize price levels. The strategy is a complete rewrite of the older RSI+PA+DCA Strategy with the goal to make it dynamic and to simplify the strategy settings to the bare minimum.
In case you are not familiar with the older RSI+PA+DCA Strategy, here is a short explanation of the idea behind the strategy:
The idea behind the strategy based on an RSI strategy of buying low. A position is entered when the RSI and moving average conditions are met. The position is closed when it reaches a specified take profit percentage. As soon as the first the position is opened multiple PA (price average) layers are setup based on a specified percentage of price drop. When the price hits the layer another position with the same position size is is opened. This causes the average cost price (the white line) to decrease. If the price drops more, another position is opened with another price average decrease as result. When the price starts rising again the different positions are separately closed when each reaches the specified take profit. The positions can be re-opened when the price drops again. And so on. When the price rises more and crosses over the average price and reached the specified Stop level (the red line) on top of it, it closes all the positions at once and cancels all orders. From that moment on it waits for another price dip before it opens a new position.
This is the old RSI+PA+DCA Strategy:
The reason to completely rewrite the code for this strategy is to create a more automated, adaptable and dynamic system. The old version is static and because of the linear use of code the amount of DCA levels were fixed to max 6 layers. If you want to add more DCA layers you manually need to change the script and add extra code. The big difference in the new version is that you can specify the amount of DCA layers in the strategy settings. The use of 'for loops' in the code gives the possibility to make this very dynamic and adaptable.
The RSI code is adapted, just like the old version, from the RSI Strategy - Buy The Dips by Coinrule and is used for study purpose. Any other low/dip finding indicator can be used as well
The distance between the DCA layers are calculated exponentially in a function. In the settings you can define the exponential scale to create the distance between the layers. The bigger the scale the bigger the distance. This calculation is not working perfectly yet and needs way more experimentation. Feel free to leave a comment if you have a better idea about this.
The idea behind generating DCA layers with a 'for loop' is inspired by the Backtesting 3commas DCA Bot v2 by rouxam .
The ideas for creating a dynamic position count and for opening and closing different positions separately based on a specified take profit are taken from the Simple_Pyramiding strategy I wrote previously.
This code is a result of a study and not intended for use as a full functioning strategy. To make the code understandable for users that are not so much introduced into pine script (like myself), every step in the code is commented to explain what it does. Hopefully it helps.
Enjoy!
Short Term Bubble RiskThis risk indicator uses the extension of the closing price to the 20W SMA and displays a color-coded risk oscillator. The higher the oscillator is, the greater the short-term risk and vice-versa. This indicator has historically worked well for estimating the short-term risk of Bitcoin and Ethereum on a weekly timeframe.
Centred Moving AverageBased around the Centered Moving Average as published by Vailant-Hero this script is revised and improved to aid with execution time & server load. For full description follow the link as above, as Valiant-Hero explains the idea perfectly well.
While the original script worked fine for small values of length, once length was extended significantly or chart timeframe set to short values then the script is prone to exceeding computation requirements. The original script was attempting to delete and re-draw (length x 3) lines on the chart for each tick. In addition to server load, once length is greater than 167 (500/3) then the first drawn lines start disappearing, so the predicted values no longer appear connected to the offset averages calculated from the candle data. A further error resulted with larger values of "length" and future data selected, in that the script would try and move lines more than 500 bars into the future.
Improvements and major code changes
All values for the predicted moving average lines are calculated from a single run through of the data, rather than having to loop back through the data "length" times (and then through it again "length" times if you selected double moving average). Each loop also inefficiently calculated the sum of "length" values by recalling each one individually.
Number of lines are thus reduced so that we're never attempting to plot more than "max_lines_count" onto the chart. User is able to select the granularity of the lines - more sections will mean a smoother line but at the expense of processing speed.
No matter the combination of "length" and the selected granularity of the lines, no line will be drawn if its endpoint would be more than 500 bars in the future.
Code for "Double SMA" only affected the predicted data values, rather than affecting the historic calculations (and standard deviation calcs) as well as the predictions. This has been included and results in much smoother lines when "Double Moving Average" is selected.
Striped lines for the predicted values - firstly to make it obvious where the "predictions" begin, and also because they look funky.
Fibonacci Moving Averages Input(FibMAI) Fibonacci Moving Averages Input is a strategy based on moving averages cross-over or cross-under signals. The bullish golden cross appears on a chart when a stock's short-term moving average crosses above its long-term moving average. The bearish death cross appears on a chart when a stock’s short-term moving average, crosses below its long-term moving average. The general market consensus values used are the 50-day moving average and the 200-day moving average.
With the (FibMAI) Fibonacci Moving Averages Input strategy you can use any value you choose for your bullish or bearish cross. For visual display purposes I have a lot of the Fib Moving Averages 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, 987 shown while hiding the chart candlesticks. But to use this indicator I click on only a couple of MA's to see if there's a notable cross-over or cross-under pattern signal. Then, most importantly, I back test those values into the FibMAI strategy Long or Short settings input.
For example, this NQ1! day chart has it's Long or Short settings input as follows:
Bullish =
FibEMA34
cross-over
FibEMA144
Bearish =
FibEMA55
cross-under
FibSMA144
As you can see you can mix or match 4 different MA's values either Exponential or Simple.
Default color settings:
Rising value = green color
Falling value = red color
Default Visual FibMA settings:
FibEMA's 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144, 233, 377, 610, 987, 1597, 2584, 4181
Default Visual MA settings:
SMA's 50, 100, 150, 200
Default Long or Short settings:
Bullish =
FibEMA34
cross-over
FibEMA144
Bearish =
FibEMA55
cross-under
FibSMA144
Crossing TableCrossing Table V1
I created this indicator as it had been asked for a number of times to create a crossover/under table screen and here it is!!!
The indicator is set up to be selected from SMA, EMA and Volume.
The SMA is defaulted to 2/10 but it is customizable to whatever SMA you choose to use.
Volume is based off a volume formula and the volume settings in the indicators settings, and the table will show either buyers/sellers on the last candle on the volume in the settings.
Just like the SMA the EMA option will be based off the default value of 5/13 but can be customized to your choosing.
If there are any question or comments just let me know :)
Bollinger Band BreakoutThis strategy buys when price crosses above an upper Bollinger Band and sells when the lower band is breached. What makes this strategy different than others:
Long only with filtering for only showing strong tickers
Filter out trades below a moving average on both the current timeframe and a longer period timeframe to keep you out of bear markets
Optional ability to set a tighter initial stop level to increase exposure and decrease downside risk on freshly opened trades while you wait for the lower Bollinger Band trailing stop to catch up
Take entries/exits on wicks/stops or wait for candle closes before entry
Select which dates to backtest
Customize Bollinger Band parameters including the ability to have different values for the upper and lower band standard deviation
Exponential Bollinger Bands (EBB)This script is a variation of the popular Bollinger Bands indicator, which uses exponential moving averages (EMA) instead of simple moving averages (SMA) as its core calculation. The indicator is designed to provide a visual representation of volatility, with the distance between the upper and lower bands being determined by the standard deviation of the underlying data.
The script starts by defining a number of helper functions that are used to calculate the moving averages and standard deviations required for the indicator. The first helper function is sma(), which calculates the simple moving average of the input data over a specified length. This function uses linear interpolation to smooth the data when the length is not an integer. The stdev() function calculates the standard deviation of the input data using the simple moving average calculated by the sma() function.
The bes() function calculates the exponential moving average of the input data over a specified length. The estdev() function calculates the standard deviation of the input data using the exponential moving average calculated by the bes() function.
The estdev function calculates the standard deviation using an exponential moving average method, rather than the traditional simple moving average method used by the stdev function. The exponential moving average method gives more weight to recent data, which can make the estdev more responsive to recent changes in volatility. This can make it more useful in certain types of analysis, such as identifying trends in volatility. Additionally, it also uses the same EMA algorithm to calculate the average value of the data set, which can help to keep the output of the estdev and average functions consistent.
The script also defines two more helper functions, average() and standard_deviation(), which allow the user to switch between using simple moving averages (SMA) and exponential moving averages (EMA) as the basis for the indicator. These functions take three arguments, the input data, the length of the moving average, and a string that specifies whether to use SMA or EMA.
The script then defines the input parameters for the indicator. The user can choose whether to use SMA or EMA as the basis for the indicator using the select parameter. The user can also specify the length of the moving average and the multiplier for the standard deviation using the length and multiplier parameters, respectively.
Finally, the script calculates the average and standard deviation of the input data using the selected method (SMA or EMA), and plots the upper and lower bands of the indicator. The upper band is calculated as the average plus the standard deviation multiplied by the specified multiplier, while the lower band is calculated as the average minus the standard deviation multiplied by the specified multiplier.
Colored Moving Averages With Close Signals[Whvntr][TradeStation]Plots the first time the close price is above or below the colored portion of the chosen MA. The MA's formula is from TradeStation's indicator: "Colored Moving Averages Can Help You Spot Trends" . I modified that indicator with customizations that include: Buy and Sell signals. Each time the current bar closes above the MA, while it's red (bearish), there's a Sell label at the start of that MA trend. Likewise: each time the current bar closes below the MA, while it's white (bullish), there's a Buy label at the beginning of that MA trend. You can now, also, easily see which MA you are selecting by hovering your cursor over the tooltips icon. I've included a modified Hull MA as default because I've found this SMA combination with the WMA to be a very smooth oscillation. I've also added some different types of MA's. Colored moving averages are helpful to determine when a trend may be reversing.
MA's
1 · Modified Hull MA: (SMA of the WMAs Hull Formula)
2 · Hull MA
3 · Exponential Moving Average
4 · Weighted Moving Average
5 · RMA Moving Average used in RSI
6 · Volume Weighted MA
7 · Simple Moving Average
This indicator isn't endorsed as a guarantee of future, favorable, results.
PSAR BBPT ZLSMA BTC 1minLong entry:
PSAR gives buy signal
BBPT prints green histogram
ZLSMA is below the price
ZLSMA has uptrend
SL is smaller than the max SL
Optional Sessions and EMA filters
Short entry
PSAR gives sell signal
BBPT prints red histogram
ZLSMA is above the price
ZLSMA has downtrend
SL is smaller than the max SL
Optional Sessions and EMA filters
SL:
Placed below ZLSMA + offset on long
Placed above ZLSMA + offset on short
TP1:
1x the SL by default
Takes no profit by default, 50% is also a good setting
TP2:
2x the SL by default
Take out all remaining position size.
If price reaches TP1, the SL is set to the entry price.
Price Cross ━ [whvntr]This oscillator is an attractive way to view hidden price divergence... The formula originated from the Lark, but I have cleanly displayed this information. When the two moving averages (ema) cross with a simple moving average, you find the hidden price divergence. What kind of market should you use this in? It works well when a trend is already established.
Disclaimer: This indicator does not constitute investment advice. Trade at your own
risk with this method of identifying hidden price divergence.
Volume Crop ━ Hidden Volume Divergence [whvntr] Volume Divergence
• Formula originated from: "Hidden Price Divergence" (circles) by TheLark. I did two things to harness its
effectiveness:
• Firstly, I developed a unique way to filter out the divergence signals that were appearing on both sides of the
midline. This filter will be known as the "Midline Tool" . It filters out a lot of the false signals commonly
associated with oscillators.
• Then, I modified the default format from Price to Volume.
• The midline formula "Midline Tool" was developed by me . It adjusts in the thousands since it's volume.
Let me know in the comments if you would rater have a smaller step value than 10,000. How does it work?
Crossover then Crossunder, the arrows only appear during the first sign of hidden volume divergence once
crossing the midline. Normally, these signs appear on both side of the midline both bearish and bullish no
matter if it's on an oversold or overbought side of the spectrum... Also, let
me know in the comments if you would like for me to release an oscillator version of this
indicator for co-witnessing.
Features:
• Volume divergence
• Midline Tool©
• Disclaimer: This indicator does not constitute investment advice. Trade at your own risk with the investments
you can afford to lose because all financial investments have risks and this is not a
guarantee that the volume divergence will be 100% all the time.
RSI and MA with Trailing Stop Loss and Take Profit (by Coinrule)The relative strength index is a momentum indicator used in technical analysis. It measures the speed and magnitude of a coin's recent price changes to evaluate overvalued or undervalued conditions in the price of that coin. The RSI is displayed as an oscillator (a line graph essentially) on a scale of zero to 100. When the RSI reaches oversold levels, it can provide a signal to go long. When the RSI reaches overbought levels, it can mark a good exit point or alternatively, an entry for a short position. Traditionally, an RSI reading of 70 or above indicates an overbought situation. A reading of 30 or below indicates an oversold condition.
A moving average (MA) calculates the average of a selected range of prices, usually closing prices, by the number of periods in that range. Essentially it is used to help smooth out price data by creating a constantly updated average price.
The Strategy enters and closes trades when the following conditions are met:
Entry Conditions:
RSI is greater than 50
MA9 is greater than MA50
RSI increases by 5
Exit Conditions:
Price increases by 1% trailing
Price decreases by 2% trailing
This strategy is back-tested from 1 January 2022 to simulate how the strategy would work in a bear market. The strategy provides good returns.
The strategy assumes each order is using 30% of the available coins to make the results more realistic and to simulate you only ran this strategy on 30% of your holdings. A trading fee of 0.1% is also taken into account and is aligned to the base fee applied on Binance.
VWMA/SMA 3Commas BotThis strategy utilizes two pairs of different Moving Averages, two Volume-Weighted Moving Averages (VWMA) and two Simple Moving Averages (SMA).
There is a FAST and SLOW version of each VWMA and SMA.
The concept behind this strategy is that volume is not taken into account when calculating a Simple Moving Average.
Simple Moving Averages are often used to determine the dominant direction of price movement and to help a trader look past any short-term volatility or 'noise' from price movement, and instead determine the OVERALL direction of price movement so that one can trade in that direction (trend-following) or look for opportunities to trade AGAINST that direction (fading).
By comparing the different movements of a Volume-Weighted Moving Average against a Simple Moving Average of the same length, a trader can get a better picture of what price movements are actually significant, helping to reduce false signals that might occur from only using Simple Moving Averages.
The practical applications of this strategy are identifying dominant directional trends. These can be found when the Volume Weighted Moving Average is moving in the same direction as the Simple Moving Average, and ideally, tracking above it.
This would indicate that there is sufficient volume supporting an uptrend or downtrend, and thus gives traders additional confirmation to potentially look for a trade in that direction.
One can initially look for the Fast VWMA to track above the Fast SMA as your initial sign of bullish confirmation (reversed for downtrending markets). Then, when the Fast VWMA crosses over the Slow SMA, one can determine additional trend strength. Finally, when the Slow VWMA crosses over the Slow SMA, one can determine that the trend is truly strong.
Traders can choose to look for trade entries at either of those triggers, depending on risk tolerance and risk appetite.
Furthermore, this strategy can be used to identify divergence or weakness in trending movements. This is very helpful for identifying potential areas to exit one's trade or even look for counter-trend trades (reversals).
These moments occur when the Volume-Weighted Moving Average, either fast or slow, begins to trade in the opposite direction as their Simple Moving Average counterpart.
For instance, if price has been trending upwards for awhile, and the Fast VWMA begins to trade underneath the Fast SMA, this is an indication that volume is beginning to falter. Uptrends need appropriate volume to continue moving with momentum, so when we see volume begin to falter, it can be a potential sign of an upcoming reversal in trend.
Depending on how quickly one wants to enter into a movement, one could look for crosses of the Fast VWMA under/over the Fast SMA, crosses of the Fast VWMA over/under the Slow SMA, or crosses over/under of the Slow VWMA and the Slow SMA.
This concept was originally published here on TradingView by ProfitProgrammers.
Here is a link to his original indicator script:
I have added onto this concept by:
converting the original indicator into a strategy tester for backtesting
adding the ability to conveniently test long or short strategies, or both
adding the ability to calculate dynamic position sizes
adding the ability to calculate dynamic stop losses and take profit levels using the Average True Range
adding the ability to exit trades based on overbought/oversold crosses of the Stochastic RSI
conveniently switch between different thresholds or speeds of the Moving Average crosses to test different strategies on different asset classes
easily hook this strategy up to 3Commas for automation via their DCA bot feature
Full credit to ProfitProgrammers for the original concept and idea.
Any feedback or suggestions are greatly appreciated.