Which stablecoin is best at keeping its peg?
Congrats! You just opened a whole can of worms! It turns out, this is a very tough philosophical question, and the sort of question that Plato had little to say about.
We know that dollars are liabilities issued by the United States, which represent a variable and typically declining purchasing power over the course of time. A dollar today is not equal to a dollar tomorrow, because of the fact that a dollar sitting under my mattress is not as powerful as a dollar in an account earning interest.
So the intrinsic value of a dollar in and of itself is already highly dependent on time and context. It gets messier when we try to go a level deeper.
Dollars don’t exist natively on-chain. Within all of “DeFi” there is never a dollar, just something that closely mimics a dollar. We create stablecoins to try to capture a close enough facsimile of a dollar. But since dollars don’t actually exist natively on-chain, we usually end up referencing the value of stablecoins relative to other stablecoins.
Redeemable stablecoins like $USDC usually can be sent to Coinbase and redeemed 1:1 for an equivalent quantity of dollars. For this reason, a stablecoin usually works pretty well as a reference asset under normal circumstances, so much so that some lazy developers simply hard-coded its value to $1 and called it a day.
The problem, as we saw this spring, is that $USDC turned out to be at risk from exposure to the precarious US banking system. When its redeemability came into question, users panicked on-chain and were only will to pay $0.90 for a $USDC. .
$USDC is worth $1 today, and was worth $1 before the depeg, but only $0.90 during the turmoil. Where did the money go during those frenzied days? We know it didn’t flow into $USDT, since that was still only redeemable for $1, right? It’s as if the money was simply erased and then magically reappeared a few days later.
It all borders on the realm of philosophy: what happens when a dollarcoin not worth a dollar? And more importantly, how can we even know?
How $crvUSD Does It
In order to build its stablecoin, $crvUSD had to come up with an onchain answer to this tricky question of: “Is $crvUSD worth a dollar?”
We know the Peg Keepers need to act to keep $crvUSD pegged to $1, but it first needed a way to figure out what $1 actually meant. The need to know what one $crvUSD is actually worth is fundamental to its Monetary Policy, which adjusts borrowing rates based on this value.
The method $crvUSD uses is to aggregate various other stablecoins and figure out what the current “price” of $crvUSD actually is.
The solution lies in the AggregatorStablePrice Contract, which has a simple price function that anybody can call to see its calculation of the current onchain price of 1 $crvUSD (times 10 ** 18).
Here is the $crvUSD solution for defining its value against a dollar. Thirty lines of code to try to strike at the truth.
One of the most important parts in the variable e
(not to be confused with Euler’s constant) This variable looks over all the various Peg Keeper pools and figures out which pool is closest to peg. Based on this, it weights the other pools based on their distance from this peg. Ultimately, all the results are aggregated together to return a truth value.
Quantifying Stablecoin Pegs
Not every stablecoin has such a robust “price oracle” we could use to try to quantify its peg. Yet we still want some way to calculate historical peg values — “which stablecoin is best at holding its peg?”
The most rigorous way to do so might be a method like the $crvUSD method above — look at all balances relative to other Curve pools and weigh them accordingly to arrive at truth values. However, we are notoriously lazy and couldn’t get this done by publication deadline, so we leave it as an exercise for the readers.
Instead, we take the simpler approach of simply exporting CoinGecko historical data and using these values to track pegs through the coin’s lifecycle.
Is this method flawed? Of course it is. During depeg events, people don’t rely on CoinGecko to establish the “truth” value of a depeg, but tend to prefer the relevant Curve pool. CoinGecko’s pricing information is very dependent on the haphazard sources of data for whichever token it’s tracking.
This parallels our approach from the last article in this series, in which we selected an imperfect but reliable measure of “decentralization” because we needed a rough estimate, and no better source readily existed.
To this end, we again encourage our many haters to one-up us not by leaving midwit replies, but by developing a better yardstick and pushing this into the broader dialogue. Create a better value for measuring pegs, and we’ll use it.
We also used CoinGecko pricing in our previous deep dive on the $crvUSD peg.
We now have over a month of data on $crvUSD, along with years of data for other stablecoins. Observe the CoinGecko pricing history of 15 stablecoins that held their peg and 2 that collapsed.
Now, this is pretty cool, but we observe it may be a bit of a rough comparison, because Tether existed for a long time in a vacuum, subject to all variety of growing pains. Let’s cut this to 2019 and onwards to cover a window where more stablecoins existed.
Evaluating Peg Formulas
We can generate a “stability” leaderboard using a few metrics. We consider three formulas.
Standard Deviation.
Computing the “standard deviation” of the daily close is about the most common measure of volatility.
We note that adding $UST and the stablecoin formerly known as $USDN to this chart, both of which are depegged, makes it hard to see the values of the coins that kept their peg. We drop them for now.
However, this would not tell us much about a hypothetical dollarcoin that quickly depegged to $0.90 and stayed there. It might have a very low standard deviation, but it’s not really fulfilling its purpose of staying true to $1 (though admittedly if it’s actually fixed at exactly $0.90 it could function as a reliable stablecoin, but we ignore this).
We might therefore consider other measures to test a stablecoin’s fidelity to $1.
Mean Absolute Error
The “mean absolute error” relative to $1, which measure deviation from this value, is a good way to judge if a stablecoin actually holds its peg at $1.
Here is how MAE reshuffles the charts:
Mostly the same tiers, but this metric most notably penalizes stablecoins like Liquity’s $LUSD and Lybra’s $eUSD, both of which almost always sit above $1.
You might consider this a drawback of this particular metric. The holder of a stablecoin don’t particularly care much if the coin tends to float above peg, only if it depegs downwards.
Therefore we can introduce a final metric…
Lower Mean Absolute Error
This only counts the volatility if the coin drops below $1 using a simple formula.
def calculate_lmae(series):
# Only measure where the stablecoin's value is below $1
series_below_one = series[series < 1]
# Calculate the absolute difference from $1
absolute_error = abs(series_below_one - 1)
# Return the mean of these absolute differences
return absolute_error.mean()
And it gives us the following:
Under this metric, $eUSD jumps from one of the worst pegs to one of the best pegs, because it almost never sits below $1.
This example also happens to show off the weakness of this particular methodology. While it may be true that $eUSD is always above $1 but volatile, this fact would do you little good if you happened to buy it on the open market at $1.10 and it dropped to $1.01. You certainly wouldn’t give it high marks for “keeping a peg.”
Formula Comparison
We will generally use standard deviation from here on out, which we feel is the best measure of pure volatility if not necessarily peg fidelity.
However, even among all three formulas, there are clearly a few common tiers. Stablecoins, like $sUSD and $alUSD, show a less strong peg, a common result for non-redeemable stablecoins. Meanwhile, $USDT, $USDC, and other redeemable stablecoins have a very tight peg.
But one coin in particular always stands out… $crvUSD is remarkably well pegged by any measure. Is this some sort of witchcraft?
Controlling for $crvUSD
We’re supposed to be assured that redeemable stablecoins are preferable to lending-based stablecoins.
One potential explanation is that $crvUSD is very new (since May 2023). Arguably it missed out on things like the 2022 Summer of Black Swans, or the $USDC depeg of this year that weighed down stablecoins with exposure to the coin.
We’ll therefore restrict the window of time for our analysis to just the timeframe since the launch of $crvUSD, to compare against a common window of time.
It’s a timeframe that has had no shortage of stress factors, $TUSD and Tether FUD has been strong in this window. Let’s redo the charts showing all three formulas
In this common window, $crvUSD is no longer in first place, but nonetheless sits firmly within the tier of redeemable stablecoins.
As Curve maxis, we’d like to take a victory lap, but we admit it’s premature. $crvUSD has not yet faced a major stress test in its existence. Nor has it yet attracted the attention of hackers who might actually attempt to force it off peg.
Most importantly, the only real liquidity source for $crvUSD is the friendly home turf of Curve itself. As it gets added elsewhere, we’d imagine we see more chaotic behavior. Our takeaway is that the early trends are encouraging, but ultimately time will tell whether $crvUSD in fact has a peg so strong it falls among the top tier of redeemable stablecoins.
What do you think? Are any of these measure preferable? Other ways to skin the cat?
Peg Implications
OK, why are we taking so much time to geek out about peg mechanics? Mostly because if we can agree on a measure to evaluate a peg, we can actually subject this to data analysis.
Let’s plot our data on peg (standard deviation) against the stablecoin’s market cap, and see what sort of conclusions we can reach.
Here we observe that while a track record of maintaining a tight peg does not guarantee a large market cap, we still observe that coins with a weaker history of maintaining peg have all failed to reach a large market cap. However, it’s only a 19% correlation.
OK, one more… does a stablecoin’s level of decentralization have anything to do with a stablecoin’s peg?
Here we consider the level of decentralization from our prior article in the series. It’s a bit skewed by $eUSD’s rather rough peg, but this only sees about a 10% correlation.
Mostly, among the strongly centralized stablecoins we see a strong peg, but among decentralized stablecoins about half are good at holding peg and half aren’t.
We hope you enjoyed this lengthy article on stablecoin pegs! Just one more in our series before we roll it up and present it at ETH-CC, so please give your feedback!