Intended Audience: This post is intended for cryptocurrency traders who engage in short-term trading strategies as well as those with a technical background that can assess the merits of algorithmic trading strategies.
Cryptocurrency Risk Disclosure: Cryptocurrency is highly speculative in nature, involves a high degree of risk, such as volatile market price swings, market manipulation, flash crashes, and cybersecurity risks. Cryptocurrency is not regulated or is lightly regulated in most countries. Cryptocurrency trading can lead to large, immediate and permanent loss of financial value. You should have appropriate knowledge and experience before engaging in cryptocurrency trading.
My Background: I'm a CFA Charterholder, statistician, python programmer, and a long-time crypto arbitrage trader. I hate risk and I hate losing money. I sought out on how to make consistent trading profits in the stock market and cryptocurrency space at the lowest risk possible. I believe I have solved this problem or at least have come very close, but you be the judge.
Algorithmic Trading Strategy: Volatility Scalp Trading
I champion simplicity over complexity. The trading algorithm does not involve AI, machine learning, back-testing, parameter-tuning, etc. Due to the nature of the trading algorithm, the concept of a losing trade does not apply.
Trading History and Results:
I've been using my trading algorithm for 18 months in the cryptocurrency space and for 12 months in the stock market. It has returned for me 41% trading profits in cryptocurrencies and 10% trading profits in stocks (this is in addition to capital gains/losses).
The Algorithm Details:
Sell 1% of your holdings for every 1.5% price increase and buy back 1.25% of your holdings with every 1.5% price decrease.
Explanation of Algorithm and Why It's Advantageous:
Let's use a simple example of a portfolio that has 5000 MATIC coins @ $1.0720 ($5,360 portfolio value)and the price increases 1.5%. The algorithm will sell 50 MATIC @ $1.0881 for $54.40. Then the algorithm's next trade will be to sell 49.5 MATIC @ $1.104 for $54.67 OR to buy 50.625 MATIC @ $1.0720 for $54.27. Let's say the price drops back to $1.072. The algorithm has now generated $0.13 cash and accumulated 0.625 MATIC coins. The back and forth selling and buying provides 1.5% gross profit where I chose to use 1.25% of the profit for coin/stock accumulation and the remaining 0.25% for cash accumulation, but you can adjust what portion to use for cash accumulation.
Scenario Consequences of the Algorithm:
- Extreme Bull Market Scenario:
If MATIC shoots to $100 a coin, the algorithm will keep selling MATIC and the user will have 233.187 MATIC left in their account and $37,847 cash for a total portfolio value of $61,291. The algorithm is designed to not cannibalize the user's holdings even if the price shoots to a $1 million as long as 1% of the holdings is not exceeded. However, this scenario generates the risk of foregone profits. If the user never sold from the beginning, they would have 5000 MATIC @ $100 for a total portfolio value of $500,000, generating foregone profits of $438,709.
- Sideways Market Scenario:
This is the perfect scenario for this trading algorithm as the price keeps going up and down within an upper and lower bound. Trading profits are constantly generated and coins are constantly accumulated, achieving far superior results than just buying and holding.
- Bear Market Scenario:
This is where the trading algorithm can get into big trouble, because if left unchecked it can wipe out the cash in a portfolio as it keeps buying the coin/stock as the price drops. To mitigate the loss of capital, I have implemented two price floors. One is for the coin. By default, I set it to 30% below current market price. In this example, I would set a price floor at $0.7504 for MATIC. This would instruct the algorithm to not execute any further buy orders below this price. The other price floor would be for the cash level of the entire account. For example, if the user has $2000 cash with the 5000 MATIC coins, then the user can enforce a price floor at $1,500. That means the algorithm will not execute any buy trades for any coins/stocks if the amount of available cash falls below $1,500. These two safeguards help the portfolio withstand to some degree a market crash.
Continuity of the Algorithm:
The algorithm is designed not to skip sell/buy trades of any intermediate price points if the price becomes much higher or lower. For example, if the last trade of MATIC was a sell at 1.104 and the application was switched off for 2 days and now the price of MATIC is $1.25 then the application will pick up right where it left off selling at $1.1206, $1.1374, and so on until it catches up. Skipping intermediate sells/buys would throw off the equilibrium of the trading portfolio, potentially overbuying and underselling a coin or vice versa.
How I've Handled the Cryptocurrency Winter Since December 2021:
During the cryptocurrency market crash in December 2021, both price floors were triggered and I had lengthy periods of no trading activity while I waited for prices to recover. During the bear market when the price floors were triggered, I adopted a strategy of only executing buy trades on crypto coins that were at least 20% below the last traded price. This wide gap differential compensated for the lack of trading volume and allowed the portfolio to start trading again sooner when prices recovered.
Polling Requirements of the Algorithm:
The algorithm checks for latest market price of coin/stock every 2 seconds. Polling as high as every 60 seconds should be also be adequate, but you may miss out on some trading opportunities, especially short-lived price spikes. Query as often as you can without surpassing the exchange's API rate limit or use websockets. API rate limits vary widely between exchanges, but typical API rate limits are between 60 - 200 API calls per minute.
Observed Weaknesses of the Algorithm:
Fungibility or a Massive Position is Required. Since the algorithm sells 1% less than the prior trade or buys 1.25% more than the prior trade, being able to trade with fractional units (such as buying/selling 1.23456 units of something) is a necessity, otherwise the precision of selling/buying the exact quantities start to break down. Most cryptos on the exchange are highly fungible with quantity decimal places 4 to 8 units out. For stocks, I used Alpaca as my brokerage firm and they allowed fractional trading on most stocks, but it wasn't allowed on certain stocks and I would need to own 7000 shares for the algorithm to trade smoothly on those stocks.
Highly Sensitive to Transaction Costs. Since the margin of profit between a round-trip buy and sell trade is 1.5%, the transaction costs would need to be under 0.25% in order to come out with a net profit of at least 1%. Most of my crypto trading occurred on Binance US (with BNB token enabled for paying transaction fee) which had a 0.0675% transaction cost on each trade. Alpaca had no transaction costs for stock trading.
Observed Strengths of the Algorithm:
Limit Order Surpluses. The algorithm would only submit a sell or buy order only when it verified that there was sufficient quantity in the bid or ask to clear the trade. As a result, most trades executed on average 0.1% better than the limit price. Furthermore, the rate of unfilled/open limit orders was less than 0.006%.
Conclusions of the Algorithm:
After trading it live for 18 months in cryptocurrency and 12 months in stocks, here's what I have to say about it. The algorithm has performed well in both cryptos and stocks. Cryptos are much more volatile than stocks so in a typical day I would see about 5 buys and 5 sells for each crypto coin and about 1 trade a day for low-volatile value stocks and about 2-3 trades a day for higher beta growth stocks. For stocks, the algorithm acted more or less as an aggressive portfolio rebalancer on steroids. Cryptos are highly correlated, they all tend to go up together and down together. With stocks, there's less correlation between them when diversified enough, so when some stocks are going up, the cash generated from sell trades are used to buy the other stocks that are going down when buy trades are triggered.
Additional Reference:
Additional details, visuals, and an introductory video can be referenced at www.krytposcalper.com
Overall conclusion:
No trading algorithm is perfect and I do not claim mines to be either. However, I challenge anyone to state a superior algorithm that has a superior risk-reward ratio than the one I proposed. I am happy with what I created and its results and will plan to continue using this while I have money in cryptos and stocks. The algorithm is very simple and any mid-level programmer can replicate it and trade for him/herself. However, many people do not know or have the time to program such an application, so a website has been created for others to download and use the product (for cryptocurrencies only, not stocks), so they can leverage this application.
I welcome the community's scrutiny and feedback. I hope to engage in a discussion that can help identify unobserved weaknesses and improve/optimize the algorithm. Thank you.
[link] [comments]
You can get bonuses upto $100 FREE BONUS when you:
π° Install these recommended apps:
π² SocialGood - 100% Crypto Back on Everyday Shopping
π² xPortal - The DeFi For The Next Billion
π² CryptoTab Browser - Lightweight, fast, and ready to mine!
π° Register on these recommended exchanges:
π‘ Binanceπ‘ Bitfinexπ‘ Bitmartπ‘ Bittrexπ‘ Bitget
π‘ CoinExπ‘ Crypto.comπ‘ Gate.ioπ‘ Huobiπ‘ Kucoin.
Comments