Learn practical skills, build real-world projects, and advance your career
Updated 4 years ago
Lending Wallet: Capital Reserve
Idea: Since we have no historical margin trading records, we can estimate the possible needs based on spot trading volume and the correlation between spot and margin trading volume.
Data-to-use:
- Exchanges choosen: BitMEX, OKEx (Bybit/FTX)
- Reason: their 24-hr trading volume is high and swaps/futures data is available (while Binance and Huobi only list their spot pairs, not derivatives)
- Why Perpetuals?
- No margin trading data available for coins (margin trading's data is mixed with spot trading in all exchanges)
- Perpetuals are continuous in time compared to futures which are discrete in time
import pandas as pd
import numpy as np
from datetime import datetime,timedelta,date
import matplotlib.pyplot as plt
import ccxt
from yahoo_fin.stock_info import *
import jovian
jovian.commit()
[jovian] Attempting to save notebook..
[jovian] Updating notebook "alexander/lending-wallet" on https://jovian.ml/
[jovian] Uploading notebook..
[jovian] Capturing environment..
[jovian] Committed successfully! https://jovian.ml/alexander/lending-wallet