delvtech / agent0

Analysis & simulation repo for Delv
https://agent0.readthedocs.io/en/latest/
Apache License 2.0
52 stars 21 forks source link

Use `calc_remove_liquidity` and `calc_redeem_withdrawal_shares` in calculating unrealized value #1684

Open slundqui opened 2 months ago

slundqui commented 2 months ago

Current lp valuation only uses lp_share_price, which can be inaccurate. Use rust calc_remove_liquidity and calc_redeem_withdrawal_shares to get these values.