Loop Markets - Whale Dependency Index

    Loop is a Decentralized Exchange cum Social Network on the Terra Blockchain. Currently the 3rd largest DEX on Terra behind the OG Terraswap and the hypothetical revolutionary Astroport, Loop can be considered one of the most Innovative and mini-ecosystem building project on Terra, with an all encompassing roadmap containing features to have a pie on every part of the Terra ecosystem.

    Loop Markets were the first to being DEX based Yield farming on Terra for Liquidity Providers. As the protocol now looks to mature, had turned to Flipside to estimate the Pool Values and its whale dependance, i.e spread of Liquidity amongst users.

    With this aim in mind, we will look into the Liquidity spread among Liquidity providers in two ways:

    1. LP token holding wallets vs Value locked in pool. This method suggested by the Loop team would give them insight on Pools which are popular amongst LPs.
    2. Calculating GINI coefficient of Value locked in pools. This is a method suggested by myself, as this quantifies the whale influence in a given Pool

    Gathering the Data :

    Gathering the data is relatively simple, thanks to Flipside's curated tables.

    • terra.msgs and terra.msg_events contain all transaction messages passed and logs emitted.
    • terra.labels identifies the necessary addresses that are Loop Pools

    The idea is to calculate the amount of LP tokens held by a certain user, by tracking their Liquidity actions. For example, when an user adds liquidity, provide_liquidity message is passed with the amount of tokens to be added, while the logs emitted by the transaction will give us the amount of liquidity tokens minted. When an user removes liquidity, withdraw_liquidity message is passed with the amount of liquidity tokens to be burned. The logs emitted will give use the tokens returned.

    Now while calculating the balances of the Pools and hence the USD value might look easy, one has to factor in Swaps made in the pool, as if a certain token in the pool appreciates in value, Impermanent Loss reduces the number of that token in the pool. While normal swaps look easy, many big transactions and arbitrage transactions are usually performed by bots or scripts, filtering is hectic a process. Since these are large volume transactions and make up a huge chunk of transactions, its necessary that these be included if the value of the Pool assets are to be calculated.

    However, as our only concern is LP whale activity, we can instead simply use the LP tokens in a wallet as a proxy of influence and shouldn't lose out on much analysis.

    1. LP token holders vs Value locked in Pool (Total LP tokens)

    Loading...

    LOOPR/LOOP has the most LP tokens, but thats not important.

    • LOOP/USD has the most number of LPs, could be a result of LOOP farming
    • LOOPR/LOOP comes second
    • In general number of Loop DEX LPs are relatively less.
    • Wormhole tokens especially lack healthy amount of LP providers

    2. Gini Coefficient vs number of LP tokens

    Loading...

    Gini coefficient quantifies wealth concentration. Higher the coefficient, higher the wealth concentration. In our case, higher the coefficient, higher the concentration of LP tokens amongst top wallets and hence higher whale dependance.

    Loading...

    As gini coefficient is a measure of wealth concentration, higher the number of LPs, more likely the Wealth is spread out. However in our case, we can see that Gini coefficient is increases as LPs increase, indicating that wealth concentration is generally higher as the number of LPs increase.

    Solutions:

    Loop Markets wants to use incentives as a means to attract more LPs, while preventing too much Wealth consolidation amongst single wallets. My suggestion would be target the pools with low number of LPs and Lower Gini coefficient. But I have no experience in LPing or running a DEX, so my opinions could be real sh*t.

    And thats it folks