File size: 239 Bytes
67400ae
 
 
 
3aa3f09
 
67400ae
 
1
2
3
4
5
6
7
8
9
import yfinance as yf

def get_asia_tech_risk(tickers):
    data = yf.download(tickers, period="2d")['Close']
    if data.empty:
        return {}
    percent_changes = data.pct_change().iloc[-1] * 100
    return percent_changes.to_dict()