Market Making Profit Estimations on bitshares and Steem-Engine Markets - (Staggered Orders)

avatar

Staggered Orders is a type of grid market hedging strategy. We assume you have already read DEXbot Staggered Orders Strategy tutorial. In this article, we will cover profit estimations for this and similar trading (market making) strategies. Using the below method you can estimate potential profits on bitshares and Steem-Engine or similar markets.

Compound interest

Compound interest formula is a basic, starting point equation for interest calculations.


formula-1.png

FV denotes future value after n trades, B is the initial balance and f is an increment between orders or spread.

Simple python code example:

B = 100
f = 0.01625
n = 100
print("Initial balance B = %d" % B)
for i in range (n):
    B= B*(f+1)  # B*f+B
print("After %d orders balance B = %d" % (n, B))

Let’s take an initial investment B = 100, growth rate f = 0.01625 (difference between buy and sell orders in per cent; 0.01625 corresponds to 1.625%). After just 600 trades balance will rise to 1 368 436 (over one million) and after 1000 trades to 1 001 287 056 (over one billion!).


plot-1.png
Fig.1

Quickly one gets mind-blowing profits. When introduced to such a great investment opportunity, a naive person will quickly jump on the bandwagon, an intelligent introvert will ask ‘OK, but what’s the catch?’ and intelligent extrovert will just exclaim ‘ It’s bullshit!’.

What’s the catch?

Compound interest formula describes exponential growth. While possible in nature, usually it can only last for a short time, as growth will quickly encounter some barriers preventing it to continue. It will quickly expand all available energy, space or other resources. At one point growth will stop or even become negative. While making yogurt, bacteria grow exponentially for a couple of hours. While fermenting beer, the number of yeast cells grows exponentially for a few hours. After that time both bacteria and yeast have used most or all of resources and growth stops. On the trading market limiting factors might be lack of liquidity or volatility. Or time required to make enough trades might be longer than lifespan, rendering strategy rather useless. Let’s consider the following conditions. Price of the asset is bouncing between 10 and 12. You buy at 10.2 and sell when it will reach 11.8. After a few dozen to few hundred trades, your balance will grow so much that your orders will absorb all market sell/buy orders at 10.2 and 11.8. Now let’s assume another trader is using the same strategy on the same market. To get trades, he will narrow spread to 10.3 and 11.7. Now your orders will not get fulfilled. You will then narrow spread to 10.4 – 11.6, where, for some time both of you will get orders fulfilled. But your balances will quickly grow and you will start to further narrow the spread. After a few hundred trades market price will stabilize very close to 11. Due in time growth rate (f factor in formula 1) gets smaller and smaller. Your orders work as a damper and limit market volatility. Your balance becomes too large for the size of the market to continue the previous growth rate.

Grid market hedging strategy profit estimation

Compound interest formula is based on the assumption that the whole initial balance (principal) is reinvested. This is not true when running the grid market hedging strategy. Only a fraction of the balance is traded at any given time. Therefore we need to modify the initial formula to suit real market volatility and fluctuations.
Let’s assume we use staggered orders strategy implemented in DEXbot and also assume that orders sizes are always the same. Each order size is only a fraction b of the current balance. Let’s assume after each trade orders are rebalanced and any profit is redistributed evenly between all orders, placed and virtual. Based on the above assumptions, a modified formula will look as follows:


formula-2.png

Simple python code example:

    B = 100
    b = 0.02
    f = 0.03
    n = 600
    print("Initial balance B = %d" % B)
    for i in range (n):
    B= B*(b*f+1)    #B= B*b*f+B
    print("After %d orders balance B = %d" % (n, B))

Note that b = 0.02 allows placing simultaneously up to ~ 25 orders below and ~ 25 orders over the middle (market) price.


plot-2.png
Fig.2

Under chosen conditions (b, f) after 600 trades balance will rise by ~20% or ~100%, respectively. Profits are not mind-blowing any more, but more realistic. Still, depending on the time required to perform 600 trades it might be a very profitable activity (although it also comes with a higher risk than 3% per annum bank deposit!). The shape of the lines in Fig. 2 now suggests as if the growth has become linear. It’s not true. Growth is still exponential, but due to the much lower growth rate (now growth rate is b*f instead of f) many more trades are required to achieve three or four digit profitability:


plot-3.png
Fig.3

Worth to note is that small changes in working balance b and increment f between buy/sell orders lead to very different profit levels when a number of trades n becomes large.

Strategy optimization

To maximize profits, you won't b, f, and n as big as possible. However, if you enlarge b, you do it by either narrowing range or choosing mountain mode instead of a valley or neutral modes. This leaves you vulnerable to bigger price changes. The price might escape outside the range boundaries and bot will stop working. If you increase f (increment or spread), fewer trades will be performed in the given time, i.e. n will be smaller. Each stick has two ends. By adjusting parameters you need to balance expected profits and risk.
Each market is different and even particular market behaves differently in different time frames, and requires an individual approach. At least in some cases, there might be more than one set of parameters that yields similar profits and risks.

Hint: to quickly calculate estimations type in the google search window:
=100(1+bf)^n for example: =100 * (1+0.08 * 0.0035)^1500



0
0
0.000
4 comments
avatar

What about a realist who could say competition or a lack of volume will erode your profits? Simple bots can be exploited it happens every day.

Micro bids are one way to fool bots. A bot needs to see the market depth and react to new bids and asks to work most effectively but that's more hardcore programming.

0
0
0.000
avatar

There are many factors that can erode profits. To cover all aspects it would require a long serious of articles.

Micro bids are one way to fool bots.

When using staggered orders strategy, depending on the parameters set, micro bids will have a difficult time to fool the bot.

0
0
0.000
avatar

Thank you so much for participating in the Partiko Delegation Plan Round 1! We really appreciate your support! As part of the delegation benefits, we just gave you a 3.00% upvote! Together, let’s change the world!

0
0
0.000
avatar

Hi @hotbit!

Your post was upvoted by @steem-ua, new Steem dApp, using UserAuthority for algorithmic post curation!
Your UA account score is currently 2.178 which ranks you at #23172 across all Steem accounts.
Your rank has dropped 152 places in the last three days (old rank 23020).

In our last Algorithmic Curation Round, consisting of 197 contributions, your post is ranked at #115.

Evaluation of your UA score:
  • Only a few people are following you, try to convince more people with good work.
  • The readers like your work!
  • Great user engagement! You rock!

Feel free to join our @steem-ua Discord server

0
0
0.000