Tuning Grid Increment in Bitcoin Grid Trading Bot

Mohammad Abandah
Coinmonks
Published in
5 min readDec 26, 2022

--

Introduction

Grid trading is a popular strategy that involves placing a series of buy and sell orders at predetermined price levels, forming a grid pattern on a chart. This strategy can be used to capitalize on market trends, volatility, or other factors. Grid trading can be done manually, but it can also be automated using a type of software called a grid trading bot.

Grid Trading bot illustration

Grid trading bots are automated investment tools that use algorithms to buy and sell assets according to a predetermined grid trading strategy. These bots can be programmed to follow a wide range of strategies, from simple to complex, and can be used to invest in a variety of assets, including stocks, cryptocurrencies, and more.

Grid trading bots can offer a convenient and potentially profitable way to trade, but they also come with their own set of risks and considerations. In this Medium story, we’ll explore the basics of grid trading bots, how they work, and what you should consider before using one.

New to trading? Try crypto trading bots or copy trading on best crypto exchanges

Grid Trading Bot Parameters

Grid trading bots typically have a number of adjustable parameters that allow users to customize their investment strategy. Here is more information about four common parameters: upper limit, lower limit, number of grids, and grid increment.

  1. Upper limit: This parameter determines the highest price at which the grid trading bot will place a sell order. For example, if the upper limit is set at 10% above the current market price, the bot will not place a sell order above this price.
  2. Lower limit: This parameter determines the lowest price at which the grid trading bot will place a buy order. For example, if the lower limit is set at 10% below the current market price, the bot will not place a buy order below this price.
  3. Number of grids: This parameter determines the number of buy and sell orders that the grid trading bot will place within the upper and lower limits. For example, if the number of grids is set to 10, the bot will place 5 buy orders below the current market price and 5 sell orders above it.
  4. Grid increment: This parameter determines the spacing between the buy and sell orders that the grid trading bot will place. For example, if the grid increment is set at $50, the bot will place orders at $50 intervals above and below the current market price.

Note: Number of grids and grid increments can be redundant when the upper and lower limits are predetermined.

These parameters can be adjusted according to the user’s preferred investment strategy and risk tolerance. It’s important to note that different grid trading bots may have different parameters and options, and users should carefully review and understand these before setting up their bot.

Why Bitcoin?

Cryptocurrency exchanges have been offering $0 trading fees for certain assets, including bitcoin, in recent years due to increased competition and changes in their business models. This trend has significantly benefited trading bots, such as grid trading bots, as they are programmed to place a large number of trades. With $0 trading fees, grid trading bots have more flexibility to adjust their positions and take advantage of market opportunities, especially in fast-moving markets.

Additionally, $0 trading fees can improve the risk-reward ratio of grid trading bots by allowing them to trade more aggressively without incurring significant costs, which can be useful in sideways markets where price fluctuations may be small. It’s important to note that other fees may apply, and it’s essential to review the fee schedule of any exchange before setting up a grid trading bot. The trend of $0 trading fees may also change over time.

Grid Increment Tuning

To evaluate the impact of the grid increment parameter on the performance of the grid trading bot, the bot will be tested with different grid increment values using real bitcoin price data from a sideways market condition, in order to remove the influence of price changes.

Bitcoin price data (04/08/2022)

The grid trading bot was tested four times with the same initial investment of $1000 and upper and lower limits of $43,900 and $42,700, respectively, which were chosen based on the available data. In order to select the grid increment value, the change in bitcoin price per minute was plotted, as the grid trading bot is designed to capture any price changes larger than the grid increment. Four tests were conducted with grid increment values of $1, $10, $50, and $100, resulting in 1200, 120, 24, and 10 grids, respectively.

Change in Bitcoin price per minute (04/08/2022)

Additionally, by plotting the grid increment against the percentage of price changes larger than the grid increment, it was found that there is a logarithmic relationship between these two variables.

Percentage of price change larger than the grid increment

Testing the grid trading bot with grid increment values of $1, $10, $50, and $100 resulted in profits of 1.71%, 1.49%, 1.12%, and 0.84%, respectively, while the bitcoin price increased by 0.66% during the same period. When accounting for the bitcoin price appreciation, the bot profits were 1.05%, 0.82%, 0.45%, and 0.18%.

Investment value of different grid increment

Finally, the chart bellow illustrates the profit percentage versus the number of grids. It can be observed that after 800 grids (a grid increment of $1.5), the profitability does not improve with an increase in the number of grids, and below 200 grids (a grid increment of $6), the profitability declines significantly as the number of grids decreases.

Percent of profit against the number of grids

Interpretation

Based on the example shown above, if the grid increment is greater than $6, or 0.0139% of the bitcoin price at that time, the grid trading bot is not effective. Many cryptocurrency exchanges have limits on the number of grids that can be used, and since the grid trading bot requires a large number of grids, it is likely to exceed these limits, making it an ineffective strategy.

Personally, I am considering researching alternative trading strategies. Do you have any suggestions?

--

--

Mohammad Abandah
Coinmonks

Discover ways to profit from cryptocurrency trading.