Algorithmic and Mechanical Forex Strategies | OneStepRemoved

  • Articles
  • Sophisticated Web Sites
  • Automated Trading
  • Testimonials
  • Contact

Using the Accumulation/Distribution Indicator

December 12, 2016 by Lior Alkalay 1 Comment

A double bottom that fails to hold, resistance that gets sliced in a heartbeat or just a trend that surprisingly breaks. Those are just a few of the”nasty” pitfalls that nearly every trader regularly encounters.  Those pitfalls are seemingly out of the blue but are, in fact, just a result of another dimension acting in parallel to the price. That dimension? The money flow. Determining where the money is flowing is exactly what the Accumulation/Distribution Indicator does and does quite well, one might add.

Accumulation/Distribution Indicator: The Basics

The Accumulation/Distribution Indicator, which was developed by Marc Chaikin, was designed to capture the accumulated money flow into an instrument.

The indicator formula factors in for each period (daily, weekly, etc.) the difference in the closing price to the lowest price and to the highest price, and the difference between the instrument’s high and low and, of course, the volume. Moreover, all of the values are accumulated; each reading is added to the last, thus accumulating the values.

The fact that the indicator is built on accumulation allows it to take into account the money flow. That provides the trader with a much clearer glance at the big picture as to how money flows over time in to or out from a pair, rather than just capturing a quick swing as many oscillators do.

The Accumulation/Distribution Indicator does not require any specific parameter; rather, the values are accumulated per candle. For example, if the period is daily, then the indicator accumulates volumes on a daily basis, and so on.

In general, as a rule of thumb, the best periods of the Accumulated/Distribution Indicator are weekly and greater. That’s because, in a daily interval scenario, the volumes can sometimes be irregularly high, often as a result of some short-term, perhaps even insignificant, event. But, for a week to have a high volume, the reason for it has to be much more significant, and that makes the indicator more effective and accurate; the higher you go on the interval, the better the accuracy, and vice versa.

Down to Practice

So, how do we translate the Accumulated/Distribution Indicator into an effective strategy? I find the most practical way to use the indicator is by stretching a trendline below it, and then dividing it into four different signals—Up, Down and Sideways (Up, then Sideways or Down, then Sideways). The Up signal is when the indicator is rising and signals an inflow of funds. The Down is when the indicator is falling and signals an outflow of funds.

In either of the two Sideways signal there is generally a freeze, an indication of low volumes and low activity. The Sideway signal is very important because it usually comes after strong inflows or outflows and it signals the exhaustion of the trend. If an Up signal turns into a Sideways signal, it means money inflows are topping out and money outflows could soon appear. If the Sideways signal comes after a Down signal it could mean that money outflows have been exhausted and money inflows could soon appear.

Accumulation /Distribution Indicator

Now, let’s examine the chart above and see how those signals can help avoid the usual pitfalls.

Resistance-

We can see that during the first Up signal, the pair was heading towards a resistance at Zone A. But what we see is that as the pair headed towards Zone A, our signal below turns from Up to Sideways. This means that, as soon as the pair reached the resistance, the money inflows stopped. The conclusion? The resistance is not likely to break. If the signal would have stayed Up, with the indicator rising, it would mean more money inflows ahead of the resistance, and that could signal a break.

Double Bottom –

In Zone B, we can see the pair has created a double bottom, a classic pattern for a rebound. And yet the Accumulation/Distribution Indicator is still Down. And that means that the double bottom pattern is not strong enough to stop the money outflows and, therefore, might not hold. Seemingly, as long as the signal is still down, the pair could trend higher (slightly) but, overall, the trend is still down, despite the double bottom. While this is not a signal for short sellers to enter into a new short position, it is certainly a signal for buyers to avoid a buy position. That is unless the signal turns Sideways. But, as long as the signal is Down, even if it is at a slower pace, the double bottom is not strong enough for a rebound.

In addition, since it’s usually mentioned in the educational materials, it’s worth mentioning here that if the Accumulation/Distribution Indicator is diverging from the price trend it means that the trend is not reliable. However, usually, the divergence will not be an outright divergence with the indicator moving in the opposite direction to a price, but more of a sideways state while the price continues to move. This, of course, suggests that the trend is weak and might end abruptly.

The Bottom Line

One other issue worth mentioning is that you should check to see if your platform enables you to see volumes on FX pairs, which is a critical component for the Accumulation/Distribution Indicator. But, once the volume is set, the Accumulation/Distribution Indicator can be counted upon and, as can be seen in our sample, can save you from many pitfalls.

Filed Under: Indicators Tagged With: double bottom, resistance, support

Correction vs Change in Trend

May 3, 2016 by Lior Alkalay 4 Comments

How many times you have seen an FX pair, or any other instrument for that matter, start moving opposite to the trend? Did you wonder was it a mere correction or were you perhaps witnessing a change in trend? Your conclusion will have an acute impact on how you choose your next trade and thus your profit or loss.

Of course, it’s impossible to be 100% certain. But here are three simple methods that could help you decide which could dramatically improve your odds of being right.

Correction zone

The first method to identify a correction or a change in trend is one I like to call the “zone method.” The idea behind it is rather simple.

When a support line has also been a resistance line it’s no longer just support and resistance. Rather, it is a border trimming between two separate zones. One is a zone where the pair is bullish and likely to move higher. The other is a zone where the pair is bearish and likely to move lower.

If that zone hasn’t changed, then it’s a temporary correction. If the zone has changed, then it’s a change in trend. From the EURUSD chart below you can see when the 1.168 was broken back in 2014, the pair moved into a bearish zone. If the EURUSD had rebounded back to the bullish zone, then that would mean the trend had changed to bullish.

zones_fin

The Trend Average

The second method that is useful in gauging a correction or trend change is done by running a moving average. The trick here is to play with the average period until it captures nearly all the trend. You can also switch between an exponential moving average and a simple moving average. Sometimes, an exponential captures the trend better and other times, a simple moving average is all you need. The idea here is to tweak, or fine tune, if you will. In our case, the trend has to be below the average.

Once you have done that, you need to see how the current correction stakes up against the rest. If the latest correction is below the average then it’s a mere correction. If the average is broken, the trend has changed, just as can be seen in the chart below.

Notice that this method is usually effective where the trend is on a rather linear path. It might work on more volatile trends but it will not always be effective.

Correction

Failed Record

The last of the simple signals is actually more a matter of probability than a proper signal. And it’s actually the simplest to identify. Simply put it is when a pair fails to break a record and it doesn’t matter if it’s a record high or record low.

Usually, three is the lucky charm. Say the pair fails to break a record on the third attempt, as in the examples below. Then, there’s a higher likelihood that this is more than a mere correction. When a record high or record low is involved, there’s a much higher likelihood that this is not a mere correction but a change in trend.

Correction

In Conclusion

As you may expect, there are many more methods to differentiate between a correction and a change in trend. Some are more advanced and complicated. Others, like Fibonacci retracement which often times is used incorrectly, tend to be misleading.

While the methods above are far from perfect, the average trader might find that they are simple and easy to implement. They could, therefore, serve him well as he tries to determine if the pair is in correction mode or an actual change in trend.

Filed Under: How does the forex market work? Tagged With: eurusd, moving average, resistance, support, trend

Trading Lessons from the Latest Gold Spike

February 19, 2016 by Lior Alkalay 10 Comments

After a relatively long period of calm, Gold has come back from the dead. Half way through February, Gold prices have spiked by more than 12%. This, of course, has got some traders scratching their head, wondering where the heck the spike came from… as if Gold moves materialize out of thin air.

Well, Gold moves don’t just “happen.” In fact, the latest spike in Gold price provides some powerful trading lessons on trading Gold.

Charting Gold Volatility with MT4

Before we jump into the lessons to be learned let’s first focus on the cycles of Gold. That should help explain the latest Gold Spike. Despite what you may have heard, Gold does have cycles. Surprisingly, the cycles are not in the price itself but in the level of volatility. In the past, I expanded on the advanced use of derivatives to predict an upcoming Gold move and direction. But the lesson here is far simpler.

In the weekly Gold chart below, we have measured Gold’s volatility through Standard Deviation (or StdDev), which is available in MetaTrader.

As one can see, Gold’s StdDev is remarkably simple to analyze. Every time the StdDev falls to 20 it jumps back up. And every time Gold’s StdDev jumps to 80 it falls down, back to the 20 low. The only exceptions were two extreme cases when the StdDev reached 145.

Moreover, we can see that if StdDev has hit lows more than once the spike of volatility higher is almost certain.

Gold

Source: MT4

First Trading Lesson

Of course, our StdDev analysis is not unique to the latest spike. But what can we learn? The first interesting lesson is that volatility spikes tend to concentrate around resistance/support levels. In our case, that is the 1,050 support, aka Point A. That means that Gold opportunities tend to occur around support and resistance levels. Now, it may seem an obvious conclusion but here is what it actually means:

When you have a support or resistance level and StdDev is at 20 that’s the ideal time for entry. You will have both textbook support and resistance levels working smoothly.  Then you’ll know that a strong momentum is coming.

Second Lesson

The second lesson is a simple but important one. A spike in Gold volatility does not necessarily mean a break of support and resistance levels. When technicals suggest that the support level will hold look at the StdDev. If the StdDev is at 20 that’s good; it re-enforces that simple fact that the support level will hold.

Third Lesson

The third lesson, which combines the first two, is perhaps the most interesting. It is the understanding that one jump in StdDev is not equal to one move. Let me elaborate; say StdDev has hit the 20 low near the 1,050 support. Meanwhile, Gold prices have spiked but StdDev hasn’t yet reached the 80 high. That means that volatility is set to rise but it doesn’t necessarily mean that Gold will keep moving in the same direction.

Rather, it means it will just move with a strong momentum. In the case above we can see Gold has hit the upper price channel resistance at Point B. But StdDev suggests volatility still hasn’t been maximized. And that means that the rise in volatility, next time, could come in the form of a short.

What Did We Learn?

So if we take our three lessons and try to summarize them, what did we learn? We learned that when StdDev is at its 20 lows it’s the best time to trade Gold. That’s because it guarantees that you will get a strong price momentum and it validates your technical analysis on Gold.

Filed Under: What's happening in the current markets? Tagged With: gold, resistance, standard deviation, support

Tips for Trading Nonfarm Payrolls

November 3, 2015 by Lior Alkalay 12 Comments

On the first Friday of each month the US Labor Department issues its Nonfarm Payrolls report. Among other labor-related data, that report provides the numbers of new US-based private sector jobs. The NFP, as it’s also sometimes called, is one of the few economic indicators that day traders and investors keenly watch.

Usually, when the Nonfarm Payrolls beats estimates, it tends to be positive for the Dollar. Opportunities for shorts, then, are created on pairs such as EUR/USD or GBP/USD, where the dollar is the counter-currency. Opportunities for longs are created in pairs where the dollar is the primary currency, like the USD/JPY.

Sounds simple, right? Well here’s the problem. Nonfarm Payrolls is one of the hardest indicators to predict. That makes it hard for the average day trader to choose a strategy, bearish or bullish, before the figure is released. In this article, I’ll share my tips for trading Nonfarm Payrolls which could tilt the balance in your favor.

When it comes to the NFP, Think like a Trader

The biggest mistake a trader can make when crafting this particular trading strategy is to think like an economist. Most economists have a tendency to predict the Nonfarm Payrolls figure in a logical, mathematical series, almost as a continuation from the previous number. But in real life, it doesn’t quite work that way.

As you can see from the chart below, the consensus tends to move in a straight line while the actual Nonfarm Payrolls figure tends to fluctuate. Does that look familiar? It should; it’s very much like the typical FX pair.

Nonfarm Payrolls

So, rather than get tangled up in a complicated statistical analysis, do the obvious. That is think the way a trader would; draw support and resistance lines.

As Illustrated below, I have simply drawn a support and resistance line above and below. When the actual Nonfarm Payrolls hits a support, you can expect it to beat the consensus in the following release. When the Nonfarm Payrolls hits a resistance level, you can expect the upcoming report to come in below estimates.

Nonfarm Payrolls

Nonfarm Payrolls: Designing a Trading Strategy

Now that you have a sense where Nonfarm Payrolls might be headed, it’s time to design a trading strategy. That’s the simple part. If you expect Nonfarm Payrolls to be a beat, then you should have a bearish trade in place. That should be on pairs such as EUR/USD, GBP/USD or any pair in which the dollar is secondary. Look for resistance levels for entry before the release and establish a bearish target.

In pairs where the dollar is a primary like the USD/JPY or USD/CHF, it’s the exact opposite. Instead, you would gear up towards a bullish strategy.

Pop quiz: What’s your trading strategy if you’re expecting NFP to miss? Yep; you got it. You should prepare for a bullish strategy when trading pairs where the dollar is secondary. And, of course, it’s vice versa in pairs where the dollar is primary.

A Few Points to Consider

Before you start, here are a few points you’ll want you to consider before trading Nonfarm Payrolls.

Does the Trade Make Sense? Say you’ve come to the conclusion that NFP will go to a certain way. And you’re pretty certain how that could affect your trade. You’ll want to ensure that all other indicators, i.e. support/resistance and buy/sell signals, are there. Don’t just buy or sell because you expect a surprise or a miss. The trade has to make sense.

During a Crisis NFP is Impossible to Predict: As can be seen on the left side of the chart, there’s an awful lot of volatility. During an economic crisis, Nonfarm Payrolls often swings so wildly that you simply cannot rely on the support/resistance band.

Nonfarm Payrolls Generate Volatility:  Let’s talk a bit more about volatility; you need to be prepared for it. Without preparation, even if you’re right, you could still end up hitting your stop loss. When a big miss or a spectacular beat occurs there is generally increased volatility. You will need to adjust your stop loss and trading strategy accordingly and quickly.

Do you want to create your own NFP chart? You can download the data directly from the Bureau of Labor Statistics. Lior created his chart in Excel using the numbers provided.

Filed Under: How does the forex market work? Tagged With: NFP, resistance, support

Trading Lessons from 2008

May 13, 2015 by Lior Alkalay 2 Comments

2008 is remembered as the year of turbulence in the financial markets. It was a year when stock prices were in utter meltdown across the globe.

Metaphorically speaking, 2008 resulted in a good, old fashioned butt kicking. It was a painful, well-deserved lesson, but ultimately a useful one that would forever change the way I trade.

Let me lay it out for you…I was well entrenched in a Martingale strategy approaching an 85% loss. I was on the verge of imploding; every single moment – awake, asleep, didn’t matter – all I thought about was trading. I was obsessed with the next one – the one I believed would put me back in the black.

From Hero to Zero

I already had three years of lucrative trading under my belt; I considered myself a superstar. I was using the Martingale technique, a simple strategy using multiple orders on the EUR/USD. When the EUR/USD was bearish I placed one order after another, each set at the next resistance level.

It worked as follows; assuming a short position, every time you hit the stop loss (typically near resistance) it simultaneously triggered a new order. The new order, though, would be twice as large (2X) as the one before.

Back then, the strategy worked amazingly well because the Euro had moved, with nary a correction, in a single unwavering direction. The pair moved first lower then higher, allowing me to gain in both directions. With more than a thousand pips movement either way, it was a pretty sweet and very profitable “system.” Looking back (and clearly showing my naiveté), I believed I had cracked the “system;” that I alone had the “edge.” I foresaw very prosperous days ahead.

On December 8th 2008, it all went haywire; a week earlier, the Federal Reserve Bank had announced the first round of stimulus. Within nine days, the EUR/USD surged a jaw dropping 2,000 pips.

The move on the EUR/USD was so quick and so aggressive that in a matter of days every order I had placed hit its stop loss. All of the profits I had made so “easily” over the previous months were completely wiped out, and then some. Everything I had built, all my “successes” and my dreams of prosperous days ahead, evaporated.

After days and days bouncing between self-flagellation and self-pity I did the only thing I could do. I took a deep breath and exhaled. I realized that that very awful event had all the earmarks of a positive learning experience, philosophically and practically. I vowed to learn, recover and prosper so that I would (fingers crossed) never have to live through it again.

 EURUSD Daily

Trading Lesson 1

With 20-20 hindsight, it’s obvious that a technique which raises risk as the market goes against you is a recipe for disaster. One day, the unexpected will occur and you will be unceremoniously thrown out of the game. So, lesson one: the amount (in Dollars, or Euro or Yen) you’re willing to risk in a trade should remain steady, even if you gain more and more.

What do I mean? Let’s say you have a portfolio of $100,000 and you risk $5,000 or 5%. If you gain over time and your account grows to $200,000 then $5,000 isn’t a 5% risk but a 2.5% risk. You’ve reduced your risk.

Why is this so important? Because the more successful you become, the greater the probability that your next trade could be a losing one. But if you reduce your risk as you gain then any potential damage can be minimized. Eventually, you may question whether or not you should you increase the amount you risk. Understand that it’s better to maintain a constant amount longer, as your risks will decline as you profit.

Trading Lesson 2

Always go up two intervals to check for support and resistance. Even if you only trade on a daily interval, you should check weekly and monthly intervals for resistance and support levels. Now, you’re probably asking yourself is that really necessary?

The answer is yes; because the higher you go on an interval, then the stronger the resistance/support. The resistance on a monthly level is certainly more significant than on a daily or hourly resistance. What you want to do is make sure that you’re not headed for a brick wall.

Trading Lesson 3

The longer the trading interval, i.e. monthly versus weekly versus daily, etc., the greater the impact fundamental and macro data will have on your trade. For example, if you trade on a weekly (or longer) interval then the decisions of a central bank or movements within an economy will determine your trade’s path.

On a long term trade, fundamentals rule and determine the direction. “Technicals,” meanwhile, let you time your entry and exit points and calibrate your risk. Given a trading style more aligned toward the longer term, this has been my most useful lesson. It has led me to specialize in macroeconomics so I can better predict how economics might affect my trade.

 

 

 

Filed Under: How does the forex market work?, Trading strategy ideas Tagged With: eurusd, Martingale, resistance, support

How Can I Tell If My Trade Will Hit Its Profit Target?

December 10, 2014 by Richard Krivo Leave a Comment

Profit Target

 

How Can I Tell If My Trade Will Hit Its Profit Target?

The short answer is that you can’t.  No matter how hard we traders wish, hope and pray, we still cannot predict the future.

As with many aspects of trading, there is no absolute answer.

The above being said, there are ways to determine if the probabilities on a particular trade might be skewed in my favor.  In other words, I have an “edge”.

Here’s what works for me…

First off, I will look at the strength of the longer term trend and the amount of room the pair has to move in the direction of my trade.  If the trend is weak and there are numerous levels of support or resistance the pair has to move through, the less likely the profit target will be hit.  If the target is hit, it will likely be a long and bumpy ride.

If the longer term trend is strong and there is little or no support or resistance in its path, the trade will have a greater probability that the profit target (limit) will be hit.

Take a look at the historical Daily chart of the NZDCHF pair below…

NZDCHF

 

We can see that the pair is in a downtrend since price has been making lower highs and lower lows and the pair has been trading below the 200 Simple Moving Average (green line) for months.   Knowing that, we are only looking for a technical reason to short the pair for a higher probability trade.

Trade in the direction of the trend and have room to move toward the target.

So, should price break support at roughly .6740, there is no support below that level until around .6440 – about 300 pips.  This is our set up.  Having a trading set up does not mean we have a winning trade.  It does not even mean that our trading setup will trigger.  It does not mean the if that .6740 level of support is breached the pair will drop like a rock.  It merely means that our set up has potential.  It is a trade in the direction of the trend with room to move when/if support is taken out.

 

On the other hand take a look at this historical Daily chart of the GBPAUD below…

GBPAUD [Read more…]

Filed Under: Trading strategy ideas, What's happening in the current markets? Tagged With: GBPAUD, NZDCHF, profit target, resistance, support, trend

Gap Trading Made Easy

April 8, 2014 by Eddie Flower 2 Comments

Gap trading with a mechanical trading system offers independent traders a relatively easy method to capitalize on sudden market moves.

Gaps are often seen in the stock and fund markets. They are somewhat less common in the forex markets, which are usually more liquid and trade overnight.

In gap trading stocks, funds, futures and forex, a price “gap” refers to the open space seen on a chart when the price moves sharply up or down with no appreciable trading in between price points.

In its simplest form, gap trading involves buying based on the rise of a gap-up, and selling on the fall of a gap-down. Put differently, gap trading means buying when a price moves beyond the high of the previous time period without trading through that high. Likewise, gap trading means selling/shorting when the price moves below the previous time period’s low without touching it.

I use mechanical trading systems to program my way toward gap trading success by following some basic gap-trading rules and algo trading strategies.

Why do trading gaps occur?

Gaps can occur for a variety of reasons, such as sudden buying or selling pressure, especially by large players. And, they may result from earnings announcements or fundamental news. In fact, gaps can follow any sudden change in investors’ perceptions about a stock, fund, future or currency.

A gap can happen for either fundamental or technical reasons. For example, if a particular company announces higher earnings than expected, its stock price may gap up during the next trading session, if not overnight. Likewise, unfavorable corporate news can spark a gap down.

Gap trading

Or, a stock, fund or future setting a new all-time or long-term high may gap up for technical reasons. That is, a price move past a certain point may trigger institutions’ buying programs, which sense those new highs and spur even more buying.

Likewise, a stock or fund whose price moves below a threshold point may trigger investors’ rush for the exits and thus push its price further downward. Down gaps tend to accelerate more sharply than upward gaps.

And, in the forex markets, any report or other news may greatly widen the bid-ask spread. This creates a tradable gap either up or down.

In any case, you can program a mechanical trading system to recognize and respond profitably for gap trading.

Classification of trading gaps

For study purposes, gaps are usually classified as one of the four types listed below. It’s important to remember that these classifications will only be confirmed in retrospect, after the gap has occurred.

Once I’ve seen the follow-up movement, these labels are useful for categorizing which type of gap has occurred. These classifications help me to better understand how a given stock, fund or currency reacts under certain market conditions.

Fortunately, when using a mechanical trading system for gap trading I don’t need to know what will happen after the gap, only the circumstances which arise just before the gap.

Common gaps are defined as gaps which cannot be otherwise classified in terms of ending one trend and beginning another. They’re very “common,” hence the name. Usually, they’re uneventful and they simply represent an unexplained price gap from one day to the next. The volume during a common gap is often low and this type of gap is generally “filled” quickly. (See below.)

Exhaustion gaps happen at or near the end of a long or strong price run-up or price drop. They signal a final push toward new highs or new lows before the price movement reverses or begins moving sideways. For me, they’re a warning that the recent move is at its end.

Exhaustion gaps are characterized by higher volume and wide price difference between the price at the previous day’s close and the next day’s opening price. Using my gap trading strategies, it’s fairly easy for me to trade and profit from this type of gap. Higher volume is the key to recognizing them.

Continuation gaps can arise in the middle of any price trend. They are sometimes also referred to as “measuring gaps” or “runaway gaps.” Continuation gaps often happen around the midway point of a strong trend.

I interpret them as showing that on a particular day an exceptionally large number of buyers or sellers chose to move into or out of their positions. Perhaps they represent buyers who didn’t get aboard the trend earlier, but who are now piling in.

As well, this type of gap shows higher-than-average volume both during and immediately after the gap. Still, the volume typically isn’t even as high as it would be with an exhaustion gap.

Breakaway gaps occur at the completion of one trend or chart pattern. They mark the start of a new trend. Breakaway gaps offer great gap trading opportunities for me. From a technical viewpoint, they occur when a price manages to break out of its mid-term trading range – say a period of several weeks — or an area of congestion.

A congestion area represents a zone between resistance and support. To break out from a congestion area, a stock, fund, future or currency must receive a significant amount of new buyer interest (on the upside) or negative attention (on the downside).

A true breakaway gap will show a very large increase in volume, whether on the upside or downside. The volume should be larger than with any other type of gap.

In any case, this represents a major turning point in price direction and in my experience the move is likely to continue for the mid-term or long-term.

I account the breakaway point as the new resistance or new support level. With my mechanical gap trading system, I look to harvest substantial gains from this type of breakout.

Most importantly, I avoid falling into the trap of assuming that a breakaway gap will retrace. Once my position is secured, I stay aboard for the ride. I’m confident that the new trend will continue for a reasonable period of time, at least until the next reversal on very high volume.

Gap fills

One other term-of-art often used to describe trading gaps is the word filled. When a gap is “filled,” it means the price has quickly returned to its pre-gap level.

Gap fills typically happen because buyers decide they were over-optimistic or over-pessimistic. Or, the news which triggered the gap is quickly proven false or overblown.

When prices move above or below technical resistance or support levels, I rely on my mechanical gap trading system to determine whether the gap is likely to be filled, and proceed accordingly.

For example, since exhaustion gaps show the end of a trend, they are likely to be filled:  The price gaps, then retraces. So, my gap trading system uses data from the previous trend to determine the appropriate entry and exit points to take advantage of both sides of this fairly predictable move.

Gap fading

Gap fading described when a price gap is filled during the same trading period when it occurs. The gap movement “fades away.” It occurs when investors’ exuberance or despair is quickly proven unfounded. This scenario often arises during earnings season.

I and other short-term traders use mechanical gap trading systems to recognize and harvest gains from these quickly-reversed moves in stocks, futures and forex markets.

General gap trading strategies

In markets that I’ve been watching closely, I use several gap trading strategies. In order to profitably trade gaps, I need to keep several things in mind.

First, it’s important to realize that when the price begins to fill its gap, it usually continues until the fill is complete. This is because a gap doesn’t have any nearby support or resistance. Otherwise, that gap wouldn’t have occurred in the first place.

Second, I keep in mind that continuation gaps and exhaustion gaps are predictors of price movements in opposite directions. So, I make sure that my mechanical trading system considers gaps in relation to the recent trend which precedes them. If not, I might trade in the wrong direction.

Also, I ensure that my gap trading system makes decisions based on volume as well as price. To help classify a trading gap for purposes of programming my algo trading system, I make a distinction between high volume, medium volume and low volume.

For a successful breakaway gap, very high volume must be present. And, exhaustion gaps are characterized by somewhat lower volumes, although still higher than usual.

I often watch stocks and funds that trade mostly during daytime sessions. Then, I program my mechanical trading system to buy their shares in after-hours trading when positive earnings are unexpectedly released.

If I’ve done my homework correctly, at the beginning of the next daytime trading session there will usually be a gap up when institutional investors crowd into the stock. As well, I use my mechanical trading system to spot and act on technical factors that signal a likely gap the next day.

This gap trading strategy also works well with currencies. My mechanical trading system tells me whether to buy or sell when a currency gaps up on low liquidity and there is no nearby overhead technical resistance. This works especially well during geopolitical events which seem likely to continue for more than one or two days.

Likewise, I use gap trading tools to profit by fading the gaps in the opposite direction. For example, if the price gaps up based on speculation when there’s nearby resistance, I fade the gap with a short order. So, I ride the price from its failed gap-up level while it goes back down to its normal price range.

Gap trading in the forex markets

The forex markets are open twenty-four hourly except for a weekend closing. So, for charting purposes forex gaps are visible as large candles when the market reopens.

Here’s the gap trading strategy that I use in forex markets. By programming my mechanical trading system with the following basic rules, I’m able to harvest satisfactory gains.

First, the direction of my trade must always be in the same direction as the current hourly price. My mechanical trading system watches for the currency to gap above or below its calculated resistance level according to a thirty-minute price chart.

Next, my system looks for a price retracement back to the calculated resistance or support level. This shows the gap is being filled — The price is returning to its previous resistance-turned-support or support-turned-resistance level.

From a charting perspective, I look for a candle showing price continuation in the same direction as the gap. My gap trading system takes this as a confirmation of continuing support or resistance at the indicated level, and trades accordingly.

Double check volume before trading

With help from my mechanical trading system including the appropriate algorithms, I’ve been enjoying good results in trading gaps in the prices of stocks, ETFs, futures and currencies.

I’ve found that volume is the most important qualification when determining the type of gap and assessing the likelihood that the price move will continue.

To avoid becoming emotionally caught up in any price move, I rely on my gap trading system to quantify and verify the volume before sending any buy or sell orders. I set my algo trading parameters to check a variety of pricing sources before generating orders.

If my mechanical trading tools detect high-volume resistance that is preventing the marketplace from filling a gap, then my system double checks the volume and price data to ensure that my trading premise is correct before proceeding.

Of course, I always program my gap trading system with appropriate stop-loss orders. Some traders believe that gap trading is risky. Yet, with the right mechanical trading tools it offers plenty of opportunities for fat gains.

In fact, gap trading by using mechanical trading systems is currently a hot topic:  A book regarding ETF gap trading has recently been published, and there are many academic reports and quant-focused articles about how to trade gaps.

I recommend that you explore the possibilities of gap trading with a good mechanical trading system. With the right tools, gap trading can be both predictable and profitable.

Filed Under: How does the forex market work?, Trading strategy ideas Tagged With: breakaway gaps, ETF trading, exhaustion gaps, forex trading, gap trading, mechanical trading, resistance, support, trading gaps

Support and Resistance Metric

September 17, 2013 by Timothy Lewkow 2 Comments

Converting back of the envelope ideas to trading algorithms is extremely challenging, but requires significant attention. This could be the single item that makes your system great. In this post, I suggest a way to find more defined support and resistance metric using limit order books.

Creating a Order Book Metric

To start, I want to create a frozen moment in time where two order books appear as in the following picture. For the sake of this example, I assume other signals have detected a $20.00 resistance level.

Support Resistance Metric Limit Order Book Comparison

Figure 1: Comparison of two limit order books during a suspected $20.00 resistance level.

Blue represents the limit bid and orange the limit ask. The order book on the left suggests strong resistance at 20, while the order book on the right suggests weakness . If you’re not convinced, see my post on the support and resistance in the limit order book.

The idea above is great in theory. How can you quantify the above two situations so that it’s actually useful? Otherwise, it’s just another fluff technical analysis piece with no real substance.

A successful method applied to Figure 1 should determined if a short position should be entered at $20.00 (left) or not (right).

The first of two decisions that you must make is how far to look into the order book — a value I will call N. The above two order books have N = 4 because each side of the book contains orders at 4 different price levels.

Of course this will depend on your access to data. However, you might also find through back testing that increasing N provides no useful information.

The next decision you have to make is how to weigh the volume in the order book.

You might be foolish to think that each level of the order book is created equally.

For simplicity, I am going to describe a linear weighting system where ticks closer to the price midpoint are given more weight. Referring to the first order book example, N=4 implies we need four weights on the ask side. My system has weights that satisfy the following conditions:

  • w1 – corresponds to $19.99
  • w2 – corresponds to $20.00
  • w3 – corresponds to $20.01
  • w4 – corresponds to $20.02
  • w1+w2+w3+w4 = 1
  • w1 > w2 > w3 > w4

These weights essentially alter the volume in the order book so that overcoming the level of resistance is a more pronounced event. Here’s how you can choose them for a linear case.

  • w1 = N = 4
  • w2 = (N-1) = 3
  • w3 = (N-2) = 2
  • w4 = (N-3) = 1
  • total = w1+w2 + w3 + w4 = 10

Through a process of normalization, the final weights are found as follows

  • w1 = N/total = 4/10 = .4 = 40%
  • w2 = (N-1)/total = 3/10 = .3 = 30%
  • w3 = (N-2)/total = 2/10 = .2 = 20%
  • w4 = (N-3)/total = 1/10 = .1 = 10%

Notice that the whole system comes by simply defining N, thus is easy to generalize and back test in your trading system.

The next step is to compute the average weighted price that would have to be paid if a market buyers chooses to pass the level of resistance. Again, I will refer to figure 1 on the ask side of the market. This will show the difference between a strong level of $20.00 resistance (left ask book) and a weak level of resistance (right ask book)

Support Resistance Metric Limit Order Book Comparison

Figure 1 repeated

Average price (left ask book) : $19.99*2+$20.00*8+$20.01*4+$20.02*5/19 = 20.0063

Average weighted price (left ask book) : $19.99*2*w1+$20.00*8*w2+$20.01*4*w3+$20.02*5*w4/(19) = 20.0022

Average price (right ask book) : $19.99*2+$20.00*8+$20.01*1+$20.02*1/12 = 20.0008

Average weighted price (right ask book) : $19.99*2*w1+$20.00*8*w2+$20.01*1*w3+$20.02*1*w4/(12) = 19.9989

From the weighting system, you can see that a assumed resistance of $20.00 is passed by only paying an average (weighted) price per share of $19.998 during a time of weak resistance.

The weighted average price shows more defined support and resistance levels

Generating Signals

Finally, to generate a solid metric, I considered the percent movement a stock would have to take to move past a weighted average price. For example:

Left ask book (strong resistance) : 100*(current price – average weighted price)/current price = 0.11%

Right ask book (weak resistance) : 100*(current price – average weighted price)/current price = 0.094%

My rule is set so that if the current price must move over 0.10% weighted average order book price (for a given value of N) then the resistance level is strong. Less that 0.10% makes me think the resistance is weak, and would signal for me to not initiate a short position.

Filed Under: Test your concepts historically, Trading strategy ideas Tagged With: average price, backtest, limit order, long, order book, resistance, short, signal, support, volume

Support and Resistance

September 11, 2013 by Timothy Lewkow Leave a Comment

The Limit Order Book is lurking behind every price tick in every market you can imagine. From the ill-liquid real estate market, all the way to high frequency bond trading, the limit order book determines all price movements.

A simple example in my last post of supply and demand demonstrated how price changes in an equity market. I made several arguments justifying the existence of a bid ask spread, and showed how this leads to price formation. My goal in this post is to find clarity in the foggy world of support and resistance using limit order books. Support and resistance information can be used to build confidence when entering or exiting a trade.

Imaginary Price Levels

If you try searching for support and resistance, a wealth of information can be found usually in the form of some article accompanied by several charts with lines claiming to have found the magical levels.

Every such chart I have found, however, has one single thing in common. The stock price always, at some point, just slightly crosses these horizontal lines. To me, it feels like a slap in the face… the ultimate I told you so from market experts that can apparently see into the future. Here’s a great example I picked up on Google.

Support and Resistance chart

Figure 1: Support and Resistance levels breached leaving question of imaginary lines.

I realize that mathematical definitions of these levels exist, and I realize that human psychological traits are often correctly considered. Nevertheless, they still lack precision! The arguments for true black and white support and resistance levels always must always have a fair amount of uncertainty. Sadly, this is just another part of working in this business.

If I see a price move past a resistance level in real time (i.e., not being able to see the entire future nicely displayed in front of me like Figure 1), I often question if the level has been breached. This could perhaps leave you in the worst possible position as the market rockets the wrong way. The limit order book can reduce this uncertainty by displaying real information.

If you try searching for support and resistance, a wealth of information can be found usually in the form of some article accompanied by several charts with lines claiming to have found the magical levels.

Suppose a stock is testing a human psychological resistance level of $20.00 and your algorithm has signaled that you initiate a short position. You wish to enter the market at the highest possible price without missing the peak. More importantly though, you wish to confirm a resistance level still exists . If the current order book is displayed as below left, you would have confidence that enough sell pressure is present to hold the resistance.

Support and Resistance limit order book

Figure 2: The left side of the image shows more market depth on the offer (orange), which is resistance. The right image shows light depth, which is the absence of resistance.

On the other hand, if the order book is displayed as above right, it it would take only a moderate collection of market order buyers to break the $20.00 level– and break it fast in this example. Short sellers would run to cover, and the market could swiftly move against you.

Measure Support and Resistance

I found some research out of Wharton suggesting an order book metric (cumulative depth), and have heard more advanced ideas shared in my personal research symposiums. That said, I think this situation is being made too complex.

Translating the above example into math should be straight forward, and customizable to the strength of signal generated by your algorithm. Allow me to suggest a crude, yet effective starting place.

Suppose you are back watching an equity as it approaches what you think to be a $20.00 resistance level. You need a metric to identify the strength of the resistance, and have one of the given order books displayed above in Figure 2. In the order book on the right, you could find the average price it would take a market buyer to pass four levels of depth. This calculation ((2*19.99+8*20+1*20.01+2*20.22)/12) shows resistance strength of 20.0008.

Using an analogous calculation on the left shows resistance strength of 20.0063, a greater value that can act as a metric defining a resistance level.

The more expensive it is to surpass a level of resistance, the less likely it will happen.

Exactly how this metric is created has many degrees of freedom. If you suspect a resistance level exists at $20.00, you could initiate a position that depends on how expensive a set of market orders would have to be to consume past the resistance. You could also alter how far deep to look when calculating the average price.

These two measures involve simple math, and provide a deeper insight to market movements. They are based on the absolute lowest levels of price formation by supply and demand, and are certainly items to consider when building a full system. In my next post, I will provide a more specific strategy to consider implementing.

Filed Under: Trading strategy ideas Tagged With: algorithm, bid, depth of market, limit order, offer, order book, resistance, support, Wharton

FREE trading strategies by email

Trending

Sorry. No data so far.

Archives

  • Dominari
  • How does the forex market work?
  • Indicators
  • MetaTrader Tips
  • MQL (for nerds)
  • NinjaTrader Tips
  • Pilum
  • QB Pro
  • Stop losing money
  • Test your concepts historically
  • Trading strategy ideas
  • Uncategorized
  • What's happening in the current markets?

Translation


Free Trading Strategies

Privacy PolicyRisk Disclosure

Copyright © 2023 OneStepRemoved.com, Inc. All Rights Reserved.