Stacked Moving AveragesThe Stacked Moving Averages indicator lets you see if a ticker is in an uptrend, downtrend, or no trend based on the condition of the moving averages. If the moving averages are stacked such that MA1>MA2>MA3>MA4>MA5, then that is described as an uptrend. If the moving averages are stacked such that MA5>MA4>MA3>MA2>MA1, then that is defined as a downtrend.
The moving averages can be SMA, EMA, or DEMA, and it’s possible to view all the moving average series in the chart or hide all series and only see if there is an uptrend or downtrend according to the condition.
Note: If length 4 OR length 5 is zero the MA4 OR MA5 will be ignored.
Sma
Quad MAFor a dive into the fine details, see the source code/documentation.
Quad MA is a program designed to allow a wide range of flexibility in overlaying multiple moving averages onto a chart.
This program handles the ability to:
- Overlay Up to 4 moving averages on the chart.
- Change the length of each moving average.
- Adjust optional values for special moving averages
(least squares and Arnaud Legoux)
- Change the color for each moving average.
- Change the type of each moving average individually.
- Change the visibility of each moving average.
- Change the source of the moving averages.
- Set alerts for a cross between any two moving averages.
Multiple Alerts by MortyMultiple Alerts by Morty
Version 1.0, Updated at 20210322
When the following signals meet the conditions, alerts will be triggered.
close price cross SMA
SMA_fast cross SMA_slow
MACD cross signal
RSI overbought and oversold
close price cross Bollinger Bands
Momentum cross 0 level
This script will also plot two MAs, EMA default ( SMA optional ).
SNAP BACK 2.0 Strategy
This strategy is designed to allow you to catch the bounce or "SNAP Back" of an equity that has been in a trend.
1) Once the moving averages are in the order of 200SMA > 50 SMA > 34EMA > 20SMA > 8EMA (or reverse for and uptrend), the strategy is setup.
2) Next you wait for a trigger of the closing price crossing the 8EMA, while there is a desired gap size between the 8EMA and the 20SMA (2-10% of stock value preferred).
3) Exit position based on target profit reached (conservative sell half at 34EMA and engage a trailing stop loss for remainder or set static limit) or price crosses 8EMA or stop loss%
*)This code also allows you to determine your desired backtesting date compliments of alanaster
This code is the product of many hours of hard work on the part of the greater tradingview community. The credit goes to everyone in the community who has put code out there for the greater good.
The idea for the coding came from a video I watched on YouTube presented by TradeStation called Snap Back - thank you guys for the inspiration.
UPDATE: I have coded the other side of the strategy to allow you to take advantage of the same set-up in an uptrend for Short plays. You can turn the up or downsides on, off, or both.
The main intent is to catch the bounces of a falling stock. However, I have found that you can do the inverse and catch the drops in a rising stock (the latter is not as reliable). This also tends to work better on less volatile stocks. I have included a large volume of user defined conditions and display entry and exit conditions on the chart to see how your choices are impacting the script.
Price Extension - ln(close/20 sma)A simple script to visualize price extension. Useful to gauge tops/oversold areas. Most useful when used on weekly tf.
Basic SMA 200 StrategyThe SMA 200 basic strategy will be more than familiar to most traders.
This strategy is to stay with the programming language so to say the "Hello World" of trading.
The SMA 200 basic strategy is also one of the simplest strategies in trading. All that is required is the price and a 200 period moving average. Usually the strategy is used in the daily chart.
The rules are as follows:
Entry: A position is opened when the price crosses the moving average 200 from the bottom to the top.
Exit: The position is closed when the price crosses the moving average from top to bottom.
This is a trend following system and was originally used for trading stocks.
In my opinion, trading with the strategy is recommended to every beginner. There are strategies with better performance, but they are much more complicated to implement. And that's where the big advantage of the strategy can be seen.
Beginners are more than overwhelmed at the beginning of their trading career. Often beginners trade in the 5 min chart with 6 different indicators some signals that they have seen in a Youtube video.
Comparable to a beginner driver who immediately gets into a Porsche as his first car.
Beginners should follow simple rules and avoid intraday charts. Above all, you should do the actual work of a trader.A trader does not just press the mouse twenty times a day and then has easily earned 2000 $. A trader tests systems down to the smallest detail, optimizes and tests again, until he has found an almost " waterproof " trading system. The 200 SMA basic strategy is excellent for gaining experience, learning to follow the rules of a system and not to burn your money right away.
With this script you can test how successful the "simplest strategy in the world" would have been in the past.
Small tip: Do not trade Forex with it it will never work. The strategy is made for long trends and you can find them for example in the stock market.
Have fun with it! About a positive feedback I would be very happy of course.
Monthly, Quaterly, Yearly SMA trendsIt highlights on the chart when the SMA20 crosses the SMA60 etc. for the Monthly, Quaterly, Yearly SMA trends.
Customizable MA RibbonAll credits to @Violent (www.tradingview.com) for making the original code! I just updated it by adding new features and themes!
---------------------------------------------
Lemon's Customizable MA Ribbon:
---------------------------------------------
A series of moving averages of different lengths that create a ribbon-like indicator. Traders can determine trend strength by lookin at the distance between the moving averages and the overall balance of the colored lines. Price movements through the ribbon can also be used to identify trend changes.
------------
FEATURES
------------
MA TYPES: SMA , EMA , WMA, RMA, ALMA, VWMA, HMA
Editable length
Editable start
User defined number of plots to show (between 1 to 32 total plots)
Multiple color theme choices
A color smoothing option.
Thank you and happy trading!
with love,
-Lemon
Stdev Breakout StrategyStdev Breakout Strategy
Description:
This script generates a long entry signal when the Standard Deviation crosses over the Simple Moving Average and the Close is greater than the Open, and/or generates a short entry signal when the Standard Deviation crosses under the Simple Moving Average and the Close is less than the Open.
Moving Average Slope to determine market directionMoving Average Slope is a straightforward but also a handy indicator.
By inserting this moving average, it is possible to glance at the direction of the trend.
When the moving average has an increasing angle, it will turn green; vice versa, it will be colored red.
It is a trend indicator; I recommend leaving the period at 20 because it includes the last four trading weeks.
If you found this indicator useful, please like it
1D Low/High MA + Least Square Mean (3 indicators in 1)This indicator is a combination of 3 public indicators being:
* a standard Simple Moving Average with the source as the candle low & length of 2
* a standard Simple Moving Average with the source as the candle high & length of 2
* the Least Square Mean with a source of high + low /2 and length of 9
This combo was inspired by Tyler Coates who crafted EMASAR.
He regularly uses the a SMA with source of Low / High and length of 2 for defining trading daily ranges as well as the Least Square Mean for calculations in the his trading which he teaches via youtube.
I hope this indicator will reduce time spent on setting up charts.
Buy/Sell/Hold/Away? This script based on Simple Moving Average and Exponential Moving Average.
The Red Line is an exponential moving average with small length. It act as a main line.
The Black Line is an average of some past data of exponential moving average. Act as Trend Line
The green circles is an exponential moving average with medium length. It act as a signal line.
The Idea is, when the price move higher from it past,past,past, repeatedly in some duration, it will gain enough energy to fly to the highest.
Buy signal when red line cross down green circle. strong buy when red line cross down black line.
Sell signal when red line cross down green circle. strong buy when red line cross down black line.
Additional 1:
Triangle up(blue) indicate Buy Signal. it happen when the price break resistant with some condition and volume>1m
Triangle down(maroon) indicate Sell Signal. it happen when the price break support with some condition and volume>1m
The more triangle show in series, the strong the trend to move accordingly.
Additional 2:
Support and Resistance line.
Hope Benefit To You All.
Scalping using RSI 2 indicator with TSLThis strategy implements a simply scalping using the RSI (calculated on two periods), the slopes of two MAs ( EMA or SMA ) having different lengths (by default, I use 50 and 200).
A trailing stop loss (%) is used.
Entry conditions:
.) Fast MA > Slow MA and Price > Slow MA and RSI < Oversold Threshold ------> go Long
.) Fast MA < Slow MA and Price < Slow MA and RSI > Overbought Threshold ------> go Short
Exit conditions:
.) Long entry condition is true and (close >= TP or close <= TSL ) ----> close short position
.) Short entry condition is true and (close <= TP or close >= TSL ) ----> close long position
The strategy performed best on Bitcoin and the most liquid and capitalized Altcoins but works excellent on volatile assets, mainly if they often go trending.
Works best on 3h - 4h time frame.
There's also an optional Volatility filter, which opens the position only if the difference between the two slopes is more than a specific value, which can be set in the study inputs. The purpose is not opening positions if the price goes sideways and the noise is way > than the signal.
Note:
.) the RSI length is 2;
.) the oversold Threshold is 90%;
.) the overbought Threshold is 10%;
.) by default, the trailing stop loss per cent is 1%;
.) by default, the fast MA length is 50;
.) by default, the slow MA length is 200;
.) by default, the MA used is EMA.
Cheers.
Customisable Moving Averages x5This is a Moving Averages pack with 5 lines.
This indicator is different from others because with it you can select the MA type used in calculations for each line.
Available MA types are (currently):
SMA
EMA
WMA
VWMA
RMA
HMA
Also configurable (for each line) are data source (open, close, hlc3, etc) and period.
PRIME IMPULSE W/ 3MAThis indicator bundle, combined with PRIME-QUARTERS, provides a trader with everything needed, on chart, to make swing and scalper entries. The short candle SMA are used to execute immediate entries, while the larger candle tf indicate Continuation, trend changes and swing points. The color coded impulse indicator used both RSI and TSI variables to determine divergences and the probability of the impending impulse thereafter. Red and green within the candles indicate bull or bearish impulses, while the yellow bars signal decreased volume and momentum for the current impulse, indicating the possible end of trend and either retracement, or Reversal. $auceCamp
PRIME-QUARTERS W-XsThis script applies both the Quaters theory for easy analysis of market structure, as well as a 50 and 800 SMA to be used in conjunction with the 4 and 21 SMA found in Prime-Pulse, to pin point sniper entries. $auceCamp
MA, MATR, ChEx | All in One - 4CR CUPIn trade position setup, we always need to determine the market structure and manage the position sizing in a short period of decision time. Indicators such as moving average, initial stop loss and trailing stop loss are always helpful.
This indicator put all these handy tools into a single toolkit, which includes the following price action and risk management indicators:
MA - Moving Average
MATR - Moving Average less Average True Range
ChEx - Chandelier Exit
This script further enhances the setting so that you can easily customize the indicators.
For both the Moving Averages and the Moving Average less Average True Range , you can pick a type of moving average which suits your analysis style from a list of commonly used moving average formulations: namely, EMA , HMA , RMA, SMA and WMA , where EMA is selected as default.
The Moving Average less Average True Range , MATR, is usually applied as a reference to set the initial stop loss whenever opening a new position.
The abbreviation, MATR, is picked, so that this can serve as a handy reminder of a very good trading framework as elaborates as below:
M – Market Structure
A – Area of Value
T – Trigger
R – Risk Management (aka. Exit Strategy)
Rainbow Trend IndicatorThis is an indicator based on the MA rainbow concept. It is possible to choose between 15 or 20 MA's and if all 15 MA's is picked, the calculation will be calculated on 15 MA's and if 20 is picked the calculation is calculated on 20 MA's. The indicator will then be a line which is assigned a value from the calculation based on the MA's. If the line is above the dashed zero line, meaning the line's last value is a positive value, the price is in a uptrend and if the line is below the dashed zero line, meaning the line's last value is a negative value, the price is in a downtrend.
In short
If the line is green, the price is in a uptrend. If the line is red, the price is in a downtrend.
Triple SMA Strategy with entries based on sma price closesHi! :)
This strategy is made for intraday trades, especially on 5 sec - 5 min charts to follow the trend.
I have not tested on higher timeframes, but feel free to play with the values.
I have set a basic value for the 3 SMA at
-200
-400
-600
We will use an oscillator for entries which is not mine. Link ->
The oscillator mentioned above is just for visualization purposes, You do not need to get the signals, but You can see how scripts are generated with different values.
When the price above/below all the 3 SMA and oscillator crosses above/below "value you set" - You will get the buy or sell signal.
Your stop will be where the slowest SMA is.
Pyramiding is set for 10.
You can manually set 3 take profit and quantity levels.
Basic values are 1 %, 2 %, and 6 % for taking profits - You can change it based on how volatile the asset is.
Basic quantity values are 30 % at each level.
Hope You find it useful :)
NMK EMA 6 + MA 9 + EMA 50Conceived by Murad Khalid
Shows the GC of EMA 6 and MA 9
Shows the DC of EMA 6 and MA 9
Use EMA 50 as the dynamic support
Combined EMA & MA crossovers [CDI]Implementation of the strategy of moving averages crossings combining two fast and two slow that are used to confirm the entry.
The purpose is to be able to quickly see a backtesting of the strategy by easily configuring the profit / loss percentage. In this script the profit percentage is used for the loss percentage as well.
Additionally you can see the moving averages all in a single chart tool.
In the community to which I belong, this strategy is used in daily candles, especially for swing trading, but it can be used in different time frames.
WARNING:
- For purpose educate only
- The entries are used under your responsibility