Discover more from All About Trading!
Trade the Nasdaq Using This Strategy
Back-testing a Strategy on the Nasdaq
This article presents an interesting strategy used to trade the Nasdaq index. It uses a less known technical indicator called the money flow index (MFI).
The Money Flow Index
The money flow index (MFI) is a technical analysis tool used by traders and investors to assess the strength and momentum of price movements in a financial instrument, such as stocks, currencies, or commodities. It combines price and volume data to provide insights into the flow of money into or out of an asset.
The MFI was developed by Gene Quong and Avrum Soudack in the 1990s as an enhancement of the more well-known Relative Strength Index (RSI). While the RSI focuses solely on price changes, the MFI incorporates trading volume as an additional factor. By considering both price and volume, the MFI aims to provide a more comprehensive picture of market sentiment and potential price reversals.
The calculation of the Money Flow Index involves several steps:
Typical Price (TP): Calculate the average price of each period, which is the sum of the high, low, and closing prices divided by three.
TP = (High + Low + Close) / 3
Raw Money Flow (RMF): Multiply TP by the volume for each period to obtain the raw money flow.
Money Flow Ratio (MFR): Calculate the ratio of positive money flow to negative money flow over a specified period (usually 14 periods).
Money Flow Index (MFI): Normalize the MFR to a scale between 0 and 100 using the RSI’s normalization formula.
Interpreting the MFI involves analyzing the value and its relationship to overbought and oversold levels. The scale ranges from 0 to 100, where values above 80 are generally considered overbought and suggest a potential price correction or reversal to the downside. Conversely, values below 20 are typically seen as oversold and indicate a possible upward price reversal.
Traders often look for divergences between the MFI and price movements. For example, if prices are making higher highs while the MFI is making lower highs, it may indicate weakening buying pressure and the possibility of a price decline. Conversely, if prices are making lower lows while the MFI is making higher lows, it may signal diminishing selling pressure and a potential price increase.
You can also check out my other newsletter The Weekly Market Sentiment Report that sends tactical directional views every weekend to highlight the important trading opportunities using a mix between sentiment analysis (COT reports, Put-Call ratio, Gamma exposure index, etc.) and technical analysis.
Creating and Back-testing the Strategy
The strategy uses a 2-period MFI with long-only parameters. Take a look at the following Figure showing a 2-period MFI applied on QQQ (Nasdaq).
The strategy gives long signals whenever the 2-period MFI dips below 5. The holding period is variable and the exit is achieved whenever the close price is higher than the previous high at any point. Here’s an example on of a bullish signal:
The back-test have shown the following equity curve.
// This source code is subject to the terms of the Mozilla Public License 2.0 at https://mozilla.org/MPL/2.0/ // © Sofien-Kaabar //@version=5 strategy("Custom Strategy NASDAQ", overlay=true) mfi = ta.mfi(close, 2) buy_signal = mfi < 5 and mfi > 5 if buy_signal strategy.entry("Long", strategy.long) strategy.close(id = "Long", when = close > high)
It’s worth noting that the results are gross of fees due to the difference in transaction costs between brokers. Make sure to find a low-fee broker for this one as it has frequent signals.
You can also check out my other newsletter The Weekly Market Analysis Report that sends tactical directional views every weekend to highlight the important trading opportunities using technical analysis that stem from modern indicators. The newsletter is free.
If you liked this article, do not hesitate to like and comment, to further the discussion!