liquidity_filter#

API documentation for tradingstrategy.utils.liquidity_filter Python module in Trading Strategy.

Module description#

Filtering Uniswap trading pairs for liquidity.

  • Used to build a trading pair universe with tradeable pairs of enough liquidity, no survivorship bias

  • See build_liquidity_summary() for usage

Functions#

build_liquidity_summary(liquidity_df, pair_ids)

Build a liquidity status of the trading pairs

get_liquidity_today(liquidity_df, pair_id[, ...])

Get the current liquidity of a trading pair

get_somewhat_realistic_max_liquidity(...[, ...])

Get the max liquidity of a trading pair over its history.

get_top_liquidity_pairs_by_base_token(...)

Get the top liquidity for pairs.