Interviews

Algo Trading with: Ankit Bits

single-image

Algorithmic trading is a method of automating trade executions through a computer program that follows a set of instructions such as price, quantity, time and even quantitative models.

This is common practice on the legacy market and it starts to become quite popular among retail crypto traders.

Today, we are going to take an in-depth at how algo traders proceed with Ankit Aggarwal, a fund manager running algos and bots on the crypto market.

Welcome Ankit, thanks for joining this conversation.

Could you introduce yourself briefly?

I am one of the Founding Partners at Bitazu Capital. I got into crypto in mid-2017 and made bank till mid-2018 by trading altcoins on spot exchanges and investing in ICO deals.

However, I lost a good chunk of it by end-2018 by knife-catching in a crypto bear market and delayed ICO projects. It was during those months that my partner & I took up algorithmic trading. Bitazu Capital has been an algo trading focused crypto hedge fund since then.

You were the winner of our trading competition organized on FTX, earlier this year. Did you use any of your automated strategies during it?

We run momentum-based trend following algos on hourly+ time-frames. Markets tend to trend only 15-30% of the time and the rest of the time they consolidate. For such a case, we need time periods greater than 6 months for the effects of market conditions on the algo to neutralise themselves.

Since, the competition on FTX was for a couple of weeks we took discretionary trades, which turned out to be well.

When did you start coding trading algorithms specifically for the crypto market?

We started coding trading algorithms at the end of 2018, and have been live with our algos in the crypto market since 2019.

The primary reasons we created algos are because:

  1. Crypto markets are 24/7 which means you can’t be awake for each and every signal of a trend trading system.
  2. A huge number of losses/drawdowns occur in a system when you let emotions to change your trades. Algos follow the system to a T.

 

How much time does it take to find the right settings? Are you constantly refining your strategy to optimize its performance?

It took us approximatively 3 months to come up with the first version of our algo. However, we are always learning and have come a long way from where we started. We were initially focused on optimizing for returns, but with time we have realized that there are other certain under-appreciated factors:

  1. Max Drawdown
  2. Length of drawdown
  3. Trades per year (makes sense when scaling and trading with bigger funds)
  4. Less reliance on Sharpe Ratio: Many people tend to favour strategies with high Sharpe ratios which makes sense for strategies that have consistent returns. However, for trend following systems with many small losses and a few big wins, Sharpe does not make sense. Sortino ratio is better as it does not punish the strategy for profitable deviations from the mean, and only punishes the loss making deviations.

 

What percentage of your fund is exclusively traded with your algos?

We trade ~70% of funds with our algos. The rest is for discretionary trades.

 

What advice would you give to someone who would like to start coding his own algos?

I have a couple pieces of advice i could give to people interested in running algos. They come from some of my practical learnings after having used *trend following algos* in the crypto market since 2019. I wish someone had told me about these pitfalls when I was starting my journey, that would have saved me a lot of time & money:

Limit orders

Don’t use limit orders for your trend following algo. 100% of the trades you won’t get filled for are winning trades Think on that! You will never miss a losing trade. In such a case, the taker fees is worth the reliability of order execution it provides.

Account for Slippage

When using market orders, slippage is a reality on whichever exchange you trade. Many algos lose their profitability when you add fees and slippage, so never forget to incorporate them in your backtests. The best way to understand approx slippage is to forward test your algo for 10-20 trades. One particularly interesting insight – employing stop market orders will slip you way more than a market order that gets triggered on candle opens/closes.

Forward Testing

Never make your funds live on an algo without forward testing the system especially when the system is new. There are many unknowns in executing the algo (reliability of execution, slippage etc.). Its better to forward test the algo for 10-20 trades to be safe.

Following the system

Every algo looks bad during drawdown, and you will surely find another system which did not have a drawdown during that period. But, you HAVE to stick to your system. Thats the hardest part of trading. Never take a discretionary decision to stop your algo, change position size etc. just because its in loss. Stick to your system.

Capital Preservation

Size and length of drawdowns are more important than only optimizing for results. If you are able to control your losses, you will be profitable in the long term.

Curve-fitting

If you ask anyone who has been in the market long enough, they will tell you that they haven’t seen a bad backtest. The primary reason for that is curve-fitting. Curve-fitted algos appear extremely good in backtests, but don’t perform well on live data as they were over-optimized. To prevent curve-fitting, try the following:

a) Don’t hard-code values

b) Run the algo on different asset types

c) Forward test before allocating main funds

d) Don’t develop the algo using all historical data available. For eg., lets say you have 4 years of data available for an asset. Only develop your algo using 2.5 years of the data, and then test on the remaining 1.5 years of data.

 

Thank your very much for your time, Ankit. It is always very insightful to get the perspective of a full time algo trader.

You may also like