Posts Tagged ‘divergence’

Example Swing VWAP / RSI Divergence Trade: $AAPL

February 8, 2019

Here’s a trade I entered in Apple about 2 weeks ago where I used the Swing VWAP and the RSI MultiDivergence indicators.

Back in January, the market had gone through a good decline. I was watching the RSI divergence on AAPL. Around that time, a big divergence showed up. This was about the largest in the last two years, and is circled on the chart below. Because of that context, I wanted to look for a long entry. After the swing low on January 3, AAPL kept above the Swing VWAP. It pulled back close to the Swing VWAP, and then on January 15 it had a bullish reversal candle (white arrow). That means the bears are losing, since it couldn’t penetrate the lower VWAP. I entered at the end of the day (yellow line) with a stop at the prior day’s low Swing VWAP (red line), and a target at $185 based on prior resistance.

So far, the trade is going according to plan. My stop is at $160 now, and I just have to manage when I take profits–at the predetermined target or in a discretionary manner. I’m really liking the Swing VWAP for how it tracks what side is winning and what side is losing. As a trader, your money comes from the losers. Markets move because they have to, and that happens because people are blown out of their incorrect positions.

Example Divergence Trade: Netflix (NASDAQ: NFLX)

October 23, 2017

Here’s a divergence trade I took last week in $NFLX, using the Multi-Divergence indicator in my trade plan. 

The setup: NFLX announced earnings on Oct 16.  Price made an all-time high.  I looked at the chart and saw a big divergence on the volume-weighted MACD.  The last big divergence in June led to a big drop. So I was looking to get in a bearish position. 

The candle on Oct 17 is the most recent bar on this chart. I saw that the bar had made the all time high and then fallen down below the prior day’s close, which I took as my bearish entry signal with NFLX at $200. 

The plan: $190 looked like a possible support, and a return to $204 would tell me my timing was wrong. I thought this move should happen in the next few days, so I bought the Nov 3 weekly options 197.5/195 put spread for $0.97.  I chose the 197.5 strike instead of the at-the-money 200 strike because it had higher gamma—it would have a larger change in delta with movement if I was right.  If the move didn’t come in the next day or so, I would get out and move on. 

I didn’t have to wait long:

The day ended red and had a good follow through day next. When the 190 support was nearly hit, I went to take profits. I sold for $1.57, which is a return of about 62%.  I love it when a plan comes together (extra Hannibal).

Note that the divergence indicator wasn’t the entry signal—it just provided context to give me an edge.  Divergences can often resolve with a continuation in the trend instead of a reversal. The context combined with the actual reversal behavior in the daily candles was what led me to take a trade. Always have a plan before you trade, and always follow your plan. My failures have come when I don’t do one or both of those things. 

Multi-Divergence Indicator for Think or Swim: MACD, RSI, CCI, On Balance Volume and many more

January 11, 2015

whatitlookslikenew

I figured out a way to combine all my divergence indicators into one single study. The new Multi-divergence script uses slopes of linear regression lines just like in the new MACD divergence indicator. This script supersedes all the other divergence scripts. The difference is now it can perform a regression on any one study of your choice from a list of ToS indicators. The indicators currently supported for divergence analysis are:

MACD, RSI, CCI, Momentum, Moneyflow, On Balance Volume, Rate of Change, Stochastic Momentum Index, Ultimate Oscillator, Volume Flow Indicator, Volume Oscillator, Volume Rate of Change, Volume-Weighted MACD, Williams Percent-R, and Woodie’s CCI

(Note that it doesn’t scan all of these for divergence at once. Just the one indicator you select. If you want to have RSI and MACD at the same time for example, you put the script on your chart twice and select the appropriate indicator for each one separately.)

If there is another built-in ToS indicator you want to have available for divergence analysis, let me know and I can add it in future updates. You can use the Multi-divergence indicator on real time charts and in scans of watch lists, and I put in alert logic so it can ping you when a divergence occurs.

This indicator is for blog donors only.  You can find it on my google site under Released Thinkscript Studies down in the Donors Only section. If you already donated in the past you can use your password to access it. If you want to become a donor (or throw me some more coin) you can do so by clicking the Donate button:

As always, if you are a DIY’er, feel free to ask questions in the comments and I’ll help answer.

UPDATE: MACD Divergence Indicator for Think or Swim

December 10, 2014

This indicator has been updated!  See the new post here.

This has been a long time in coming.  My family life has been in upheaval for a couple years now.  I finally had a bit of time so I wanted to get this done.  Thanks for staying with me.

Many people have asked for a version of the MACD Divergence Indicator that can run in a scan.  The old one I had ran on recursive logic and so wasn’t supported in scans.  This new one uses a different philosophy that runs in real time.  Before I would use my Swing Points and check the value of the MACD against them.  Higher swing highs and lower corresponding values of MACD on those bars would signal a bearish divergence.  Now I am using Linear Regression slopes to compare divergences.  Here’s the theory of how it works:

A linear regression is a way to fit a straight line through some data such that you get the least amount of average distance from the line. If the slope of the linear regression is up, then values are generally trending upward over the set of data you put in. If the slope is negative, then the values trend downward.

So I take a linear regression of price, then get the slope of the LR, and I also take a linear regression of the standard MACD indicator and get that slope. When the price slope is positive and the MACD slope is negative, we have a bearish MACD divergence. If price slope is negative and MACD slope is positive, we have a bullish divergence. If price slope and MACD slope are the same, we have a trend continuation (up/up or down/down). This chart shows this theory in action:

howitworks

 

Here’s what my indicator actually looks like.  The small arrows are short term divergences, the larger arrows are the long term divergences.  The short and long timeframes are inputs, so you can set them at whatever you want.  This chart uses 20 and 50 as the inputs, but you can experiment with what works best for what you are trading:

whatitlookslikenew

As with all divergences, just because it is there doesn’t mean that the trend must reverse. Sometimes divergences can go on for a long time. This information is good to give you a sense that a trend might reverse, and you can plan your own entry and stop accordingly.

Now, to set set up a custom scan, you follow the instructions in these pictures:

scan1

scan2

Then when your scan runs, you will get flagged if the divergence you asked for is currently found.

This indicator is for blog donors only.  You can find it on my google site under Released Thinkscript Studies down in the Donors Only section.

RSI Divergence Indicator for Think or Swim

January 12, 2010

This indicator has been updated!  See the new post here.

In a similar vein to my MACD and CCI Divergence indicators, here’s an indicator that checks for divergences between RSI and price. It’s basically just a modified version of the CCI divergence indicator I did, but using RSI instead. Also added is a filter that only plots signals if a bearish divergence is in overbought territory, and if a bullish divergence is in the oversold area. There are two indicators. The first, “Pro_RSIDivergence_v1STUDY.ts” looks for when the RSI values diverge from price making new swing highs or lows. The second, “Pro_LowerRSIDivergence_v1STUDY.ts” reverses the process, looking for price to diverge from new swing highs or lows on the RSI indicator itself, and is plotted in the lower panel. I would tend to use the upper one only, but you may want the other one, so I did it. I also added the alert code block that I highlighted earlier, so you can let it run on a chart and get alerted if a divergence shows up.

The two studies are found in “Pro_RSIDivergence_v1.zip” and can be downloaded in the “Donors Only” section of “Released Thinkscript Studies” on my Google site. As always, home-gamers can ask me any questions if they want to make one for free by themselves. The CCI tutorial covers all the same coding I used for this one.