**part 1 **
Evaluate the distribution of various target segments who provide liquidity (LP):
- What’s the total no. of unique LP providers?
- What’s the ratio between Yield farmers vs. LP Providers?
- What’s the average no. of LP positions opened by each unique wallet address
- What’s the ratio of liquidity (Based on TVL) owned by the Protocol vs. Retail LP in both LP Pool and yield
Approach
To Identify liquidity providers, I have used the following code
from ethereum.core.fact_event_logs
where ORIGIN_TO_ADDRESS = '0xd9e1ce17f2641f24ae83637ab66a2cca9c378b9f' and EVENT_INPUTS:from = '0x0000000000000000000000000000000000000000'
and obtained all of information needed.
In order to identify yield farming actions and users, the code was
from
ethereum.core.fact_event_logs
where
ORIGIN_TO_ADDRESS = '0xef0881ec094552b2e128cf945ef17a6752b4ec5d'
and
EVENT_INPUTS:from = ORIGIN_FROM_ADDRESS
and EVENT_NAME = 'Transfer'
RESULTS
-
The results show a downturn trend for LP actions and also number of unique lpers.The downturn started from early days of 2022 and still continues.Dec 27 and october 11 were top days in terms of lp providers with over 4k unique users doing over 6k lp transactions.
-
In terms of yield farming, the story is almost same. looking at the weekly number of yield farming transactions and yield farmers count, the maximum amount for this metrics occurred on June 7 and 27 Dec 2021, with 19k and 16k users respectively, doing 29 k and 20 k transactions.
-
the total no. of unique LP providers is 93.5k , which have done 390K LP transactions, so the average no. of LP positions opened by each unique wallet address is 4.18 .
-
the ratio between Yield farmers vs. LP Providers is 15.43%,it means that, 15.43% of LPers, did yield farming.
-
the ratio of liquidity (Based on TVL) owned by the Protocol vs. Retail LP in LP Pools and yield is above 99% in retail LP side for both items
part 2
Evaluate the profitability of an LP Provider & Yield Farmer
- Evaluate if there’s a correlation between profitability vs. length of time?
- Evaluate if there is a correlation between profit vs. time of withdrawal
- Correlation between profitability vs type of pool?
Approach and Results
-
correlation between profitability vs. length of time
To answer the questions above, I considered the min (block_timestamp) as deposit time and max(block_timestamp) as withdraw time and summarized the amount usd deposited and withdrawn by each user, and then using datediff() function, found the relation between length of lp and profit gained by users.
the results show that, in most cases, the longer the length of time is, the more more the profit would be (in LP actions) .
in terms of yield farming, it seems thet, 4-6 months is the most profitable time range , and after that, 2-4 month, and 1 month are the most profitable time ranges respectively. so, it can be said that, there is a relatively positive correlation between timerange and gained profit in bpth lp and yield farming .
\
-
correlation between profit vs. time of withdrawal
I have calculated the net gained value for each month during last year, for both LP and Yield farming actions.According to the charts, by the time going and getting closer to 2022, the loss is getting lower and lower and then profits start to appear gfor LP actions. ALthough, the first three months of 2022 were not ideal , other months were good and profitable. so, it can be said that, withdraws in 2022 and after FEB were more profitable than before that date.
For yield farming, It seems that, the situation is quite inverse.Getting closer to 2022, the profit is getting lower and the loss is getting more. so, the 2021 was more ideal than 2022 for yield farmers to withdraw. these two analyzed situations, could be considered somehow as a correlation, positive for LP and Negative for yield farming!
-
profitability by pools
A list of 50 most profitable pools is provided for LP actions which ebtc-weth , link - weth , dai-weth and sushi-weth were the 4 most profitable pools respectively.rest can be found from the chart