Strategy 5 – We’re cooking with gas now.
Finding an edge after the popular “Gap and Go” strategy. This strategy made $170k in the past two years (750 trades) with a 66% ROR, 15% MaxDD, 1.3 profit factor, and a 2.1 Sharpe ratio.
Disclaimer: the following post is an organized representation of my research and project notes. It doesn’t represent any type of advice, financial or otherwise. Its purpose is to be informative and educational. Backtest results are based on historical data, not real-time data. There is no guarantee that these hypothetical results will continue in the future. Day trading is extremely risky, and I do not suggest running any of these strategies live.
Update:
This strategy was originally published for paid subscribers only but has since then been set free. As of this writing (on 09/05/2024), this strategy still has decent backtest results and decent out of sample results. Below is a screen shot of the results showing in-sample and out-of-sample results for this strategy:
It has had almost 100 trades since tested last and has maintained roughly the same performance as when it was tested with the out-of-sample data.
That being said, there are a couple of things that need to be considered with this strategy that I didn’t know before I created it.
Norgate Data does not have historical fundamental data. That means that the market cap and float figures used in this strategy are not reliable when backtesting over long periods of time. Because of this, you can only use limited history when backtesting this strategy to minimize the effects of having incorrect fundamental data during testing.
It also uses a HUGE universe of stocks. As in all of them. I don’t know if this is truly ideal or not for this type of strategy.
All calculations are done with raw price and indicator values. Nothing has been normalized or scaled.
Hope you enjoy the strategy. If you have any questions or comments, feel free to reach out. To see more strategies, you can become a paid subscriber and get access to two strategies a month plus all updates to the code base on the GitHub repo.
This strategy doesn’t use a single indicator we have discussed the past two months. Actually, it barely uses an indicator at all. This strategy uses an exponential moving average, but it’s hardly fair to call a moving average a trading indicator, exponential or not. Instead, this strategy uses a popular day trading strategy called the “Gap and Go”. This strategy was popularized by Ross Cameron (Warrior Trading), and you can find the criteria for this strategy all over the internet and on YouTube.
Here are a couple links:
The Simplest Day Trading Strategy: Gap and Go ↗️📈 #stockmarket #daytrading (youtube.com)
How To Trade Gap Up and Gap Down Strategy - YouTube
You can find different variations of this strategy all over the internet. I will focus on the version that Ross Cameron, an expert momentum trader, talks about and trades all the time.
Stocks have a market capital above 50 million and under 2 billion. This is referred to as a small-cap stock.
The stock has a low float, which is the number of shares available for trading by the public.
The stock has “gapped” up a certain percentage. This means that the stock’s open is above the previous bar’s close.
The stock’s price is usually under $100. This is not a hard rule. Ross Cameron will focus on the lower side of this (between $5-20) when discussing building a small account through day trading, and it is the price range I will focus on for this strategy.
That’s it. The beauty of this strategy is its adaptability. Certain parts can be adjusted, depending on the size of your account and risk tolerance. The part that might differ between traders is timing entry and what technical features you want to look at for planning a trade entry, giving you the power to tailor it to your needs.
I appreciate you breaking down the criteria of this trading strategy, Larry, but if this strategy is easily found on the internet for free, what makes your strategy different, and why do I care?
Because, other Larry, we don’t actually trade this strategy as intended. Instead, we use the criteria in this strategy to create a new strategy that doesn’t trade these stocks until after a successful “gap and go” trading day.
There is an old saying. Something about old dogs and new tricks?
Is this your way of prepping us for another…
Lesson from the Past
One of the many interesting people that I got to work with overseas was a man who used to be a Force Recon Marine. Let’s call him John. John was a cool dude. I’m not sure what he was doing working WPS contracts (yeah, I do, the money), but it was nice to have guys with his kind of experience working with us.
If you know anything about military guys, there is almost always a “no shit, there I was” story when you are sitting around waiting for too long. One of the stories John told me has always stuck with me. It was a story about a mission that almost happened.
Have you ever heard of Abu Musab al-Zarqawi? You may not know that name or his real name (Ahmad Fadhil Nazzal al-Khalaylah), but you have probably heard of ISIS. Zarqawi was the man who started ISIS and was one of the most deadly and sought-after terrorists in Iraq in the early/mid 2000’s.
John told me a story about how his team had been spun up to train for a ground assault mission in Iraq to go after an HVT (high-value target). Later, he discovered that the intended target was Zarqawi. He said that his team started training for the mission, and when the time got closer, they were stood down on the mission, and a Different group of special operations guys were chosen to run the mission instead.
This isn’t an unheard-of practice in the world of special operations. From my understanding, they will spin up several different teams for the same mission and then choose the more appropriate team to run the mission. I’m not sure what the criteria for choosing are (because I am not JSOC), but in this particular case, it didn’t matter.
At some point (right before the mission, according to John), it was decided that a ground assault wouldn’t be feasible. It’s easy to assume why this decision was made. The risk for failure and the risk for the operators on the ground were too significant to green-light a ground assault. So, they fell back on a faithful American favorite, a tried-and-true option.
The bomb.
The team intended for the ground mission became the team for body recovery and target identification instead.
Old dog, same tricks.
John always ended this story with some good old-fashioned shit talking about the team that was supposed to run the mission but ended up running recovery instead. According to him, his team could have pulled it off without using a bomb. I can’t speak to the accuracy of this statement. Still, a quick search online or reading any of the several books written about the US involvement in the Middle East confirms how the operation concluded.
Whether John was talking shit or whether he truly believed what he was saying is unknown. What is known is that there is ALWAYS a risk to operators when you assault the Alamo. There are three rules for close-quarters battle (CQB): surprise, speed, and violence of action. Once the “surprise” portion is gone, the risk assumed by the operators jumps up tremendously.
Back to the Present
When compared to trading, the risk in the above scenario can be connected to the drawdown and failure risk of a trade (albeit a bit more macabre). A trade strategy with a large failure risk, or a strategy with a large drawdown risk, might be an unacceptable risk for most traders. The gap-and-go strategy is no exception. There is a lot of risk associated with this type of trading strategy. It requires good scanners and a lot of practice to trade this system correctly. It can be turned into a automated trading strategy, but it would require a lot of streaming data and investment up front. It would also be competing with a lot of major funds for space. You would also need a way to find predictable catalysts. The list goes on. However, after some analysis, I have found an alternative strategy that could potentially mitigate these risks.
Like the Zarqawi mission, there is no need to take an unnecessary risk. We have good intel about our target’s location. In our case, that is the successful gap-and-go strategy. Instead of playing the same game as everyone else, I decided to see if there was another option that didn’t require as much risk. I was looking for a different edge. I wasn’t expecting to find that edge so quickly. It started as a simple idea I played with over the weekend. Since RealTest makes writing strategies quick, I figured I could type it out and see if there was anything there.
It turns out there is. I’m willing to bet I am not the first to find it, either.
Backtest Results
The backtest results shown here are for both the long and short sides of this strategy. Both sides are profitable, but the long side makes more trades than the short.
The results are also compared to a buy-and-hold benchmark strategy on SPY.
Trades are only held for a maximum of one day, so it is a day trade and not a swing trade strategy.
I used Norgate Data to test this strategy. They have a good trial offer for anyone interested in checking out their data. It gives you access to all data for the past two years, which is why this is tested on 2 years of data.
This strategy was tested using the RealTest platform. That means the code for this strategy is written in RealTest Script. This scripting language is pretty damn simple and can be adapted into any programming language as necessary.
I want to point out one big caveat to the previous statement; RealTest is one of the few backtesting platforms that makes testing multiple strategies on multiple assets easy. That is the superpower of this backtesting engine. Converting this to a different platform (NinjaTrader, TradeStation, etc) may not be as straightforward as it is here. It is possible; I just haven’t attempted to do so yet. As soon as one of you reaches out to me and asks me to see if I can replicate this on a different platform, I will find out exactly how difficult it is.
The best bet would be to convert it into a custom backtesting engine, such as the one found at HangukQuant’s Newsletter, or create your own backtesting engine (which I plan to start trying to do after this post).
Summary Stats:
Equity Graph:
Drawdown:
Monte Carlo Analysis: This shows the top/bottom 5 results out of 100 samples.
Remember, HGT is a reader-supported newsletter. I don’t have any affiliation relationships or sponsors. The only income I receive from this Substack is from the subscribers, and it will always be that way. If you like what you are reading and want to support this newsletter’s growth (what I learn, you learn, no secrets here), you can become a paid subscriber. I am getting better at this every day, and I want to continue to document this journey and help anyone else who is driven to become self-sufficient in the market.
The rest of this post is for paid subscribers. Paid subscribers will have access to the private GitHub where all the Hunt Gather Trade code and strategies live. It is continuously being worked on and will expand as we explore the world of automated trade systems.
Strategy 4 Logic
This strategy focuses on identifying small-cap, low-float stocks that made a significant “gap and go” move. The EMA(9) is only used for the short side of this strategy. Entry orders are limit orders, and target/stop orders are placed for each trade taken. If a trade does not hit the target or stop before the close, a trade will be closed at the end of the trading day.
Stocks in Play
Price Range: The stock price must be between $5 and $20.
Gap Up: The opening price must be at least 3% higher than the previous close.
High Relative Volume: The stock must have a relative volume of at least 1.5 compared to the average volume over the past 10 days.
Market Capitalization: The stock must have a market cap between $100 million and $2 billion.
Float: The stock must have a float of 50 million shares or less.
Long Trade Criteria
Meet the “Stocks in Play” criteria.
Daily Gain: The stock must have gained at least 2% from the open to the close.
Entry Limit: The stock must trade below the close of the setup day by a quarter of the 5-day ATR (Average True Range).
Exit Criteria: The trade is exited if the stock reaches 25% above the entry price (Exit Limit) or 15% below the entry price (Exit Stop), or at the close of the trading day.
Short Trade Criteria
Meet the “Stocks in Play” criteria.
Daily Loss: The stock must have lost at least 2% from the open to the close.
Open Above EMA: The stock must open above the 9-day EMA by a specified threshold (default 24%).
Entry Limit: The stock must trade above the close of the setup day by a quarter of the 5-day ATR.
Exit Criteria: The trade is exited if the stock reaches 10% below the entry price (Exit Limit) or 15% above the entry price (Exit Stop), or at the close of the trading day.
Code
The strategy implementation is written in RealTest. The code is structured to define the criteria for identifying potential stocks, set up the parameters for long and short trades, and specify the entry and exit rules for the trades.
Notes: Is there an edge the day after a small cap/low float stock makes a gap and go move?
This strategy takes the gap and go criteria from Ross Cameron's (Warrior Trading)
daily trading strategy and attempts to see if there is any predictability of returns the
day after the move.
Import: // requires Norgate Platinum subscription
DataSource: Norgate
IncludeList: .@CurrentStockUniverse
IncludeList: SPY
StartDate: 1/1/20
EndDate: Latest
SaveAs: sc_gappers.rtd
Fundamentals: mktcap
Settings: DataFile: sc_gappers.rtd
StartDate: 01/01/20
EndDate: Latest
BarSize: Daily
AccountSize: 100000
Parameters:
gap_percent: from 3 to 15 step 1 def 3
gain_percent: 2
vol_lookback: 10
r_vol_threshold: 1.5
long_positions: 5
short_positions: 2
s5_allocation: 100
ema_gap_threshold: from 15 to 50 step 1 def 24
Benchmark: Benchmark
// Buy and hold SPY as a benchmark.
// Exit and immediately re-enter on each ex-dividend day to re-invest the dividend.
Side: Long
EntrySetup: Symbol=$SPY
ExitRule: Dividend > 0
Data:
price_range: C >= 5 and C <= 20
gap_up: (O - C[1]) / C[1] * 100 >= gap_percent
gap_down: (O - C[1]) / C[1] * 100 <= -gap_percent
gain: (C - O) / O * 100 >= gain_percent
loss: (C - O) / O * 100 <= -gain_percent
small_cap: F.mktcap >= 100 and F.mktcap <= 2000
low_float: InfoFloat <= (50 * 1e6)
// Relative volume calculation
avg_volume: Avg(V, vol_lookback)
relative_volume: V / avg_volume
high_relative_volume: relative_volume >= r_vol_threshold
// For setting entry limit
atr5: ATR(5) // Used for setting entry limit
short_entry_limit: C + (atr5 * .25)
long_entry_limit: C - (atr5 * .25)
ema9: EMA(C, 9)
open_above_ema: O > (ema9 * (1 + (ema_gap_threshold / 100)))
long_setup: price_range and gap_up and high_relative_volume and gain and low_float and small_cap
short_setup: price_range and gap_up and high_relative_volume and loss and low_float and small_cap and open_above_ema
Charts:
ema9: EMA(C, 9)
Template: common
Allocation: S.Equity
QtyType: Percent
Commission: Max(1, 0.005 * Shares)
LimitExtra: 0.001 * C
Strategy: short_gap_losers
Using: common
Side: Short
Quantity: s5_allocation/short_positions
EntrySetup: short_setup
EntryLimit: short_entry_limit
ExitLimit: FillPrice * 0.9
ExitStop: FillPrice * 1.15
ExitRule: 1
ExitTime: ThisClose
Strategy: long_gap_gainers
Using: common
Side: Long
Quantity: s5_allocation/long_positions
EntrySetup: long_setup
EntryLimit: long_entry_limit
ExitLimit: FillPrice * 1.25
ExitStop: FillPrice * 0.85
ExitRule: 1
ExitTime: ThisClose
Conclusion
This strategy leverages the well-known “Gap and Go” methodology, applying it to small-cap, low-float stocks to identify potential trading opportunities. The strategy aims to capture predictable returns the day after a major gap move by focusing on high relative volume and significant price movements. The parameters used in this strategy can easily be adjusted/optimized.
This might be the last strategy I post for a couple of weeks. I have a couple of research topics that I want to explore, and I want to work on putting together a simple (but fast) Python backtesting library. I will post everything I learn through that process here. Of course, if I think of a strategy during this process and the test results look good, I will share it.
If you couldn’t tell, I publish my posts the second I am done writing and editing them. I don’t believe in sticking to a specific schedule or holding a post for another week just because I already posted one. Just like trading, there will be times when I am super efficient/prolific (ups), and there will be times when I am not (downs). I am a human (and a dad). This is how things work in the real world. Creating a schedule for posts only makes the process more stressful. It also feels like I am withholding from the community, which isn’t what I want. It likely isn’t what you want, either.
As I learn, I write; as I write, I post.
I have no intention of ever withholding anything I learn from the community. I have no boss (except my wife), no company, no shadow group of friends, I don’t subscribe to shareholder wealth maximization, and I don’t believe in keeping secrets. This is why I will always be poor, but it’s okay. It will not be a regret on my deathbed.
We are a society of individuals who like to pretend that we think about other people, but our actions show our true nature. We only care about ourselves (general rule). I plan to have my actions speak for themselves, not the other way around.
Don’t pay attention to the lips; pay attention to the hands.
Stay cool, HGT members.
Happy hunting!
The code for strategies and the custom functions/framework I use for strategy development in Python and NinjaScript can be found at the Hunt Gather Trade GitHub. This code repository will house all code related to articles and strategy development. If there are any paid subscribers without access, please contact me via e-mail. I do my best to invite members quickly after they subscribe. That being said, please try and make sure the e-mail you use with Substack is the e-mail associated with GitHub. It is difficult to track members otherwise.
Hunt-Gather-Trade/real-test-scripts: A collection of trade strategies for RealTest (github.com)
Feel free to comment below or e-mail me if you need help with anything, wish to criticize, or have thoughts on improvements. Paid subscribers can access this code and more at the private HGT GitHub repo. As always, this newsletter represents refined versions of my research notes. That means these notes are plastic. There could be mistakes or better ways to accomplish what I am trying to do. Nothing is perfect, and I always look for ways to improve my techniques.