K
K
KopatychKosalapov2021-07-10 17:23:37
Python
KopatychKosalapov, 2021-07-10 17:23:37

By some miracle, I got this error (Exception in thread Thread-1: Traceback (most recent call last :))?

Colleagues, good afternoon!
Since I have rather little experience in learning in pythone and doing analytics, I was able to figure out one hodgepodge.
At the same time, thanks to it, I unloaded the data and wrote it to a csv file, and today it gives an error: (Exception in thread Thread-1: Traceback (most recent call last):), Perhaps my script will fail due to a change in Internet provider?

Script example

import yfinance as yf
import pandas as pd
import csv

tickers_list = [
"CBOM.ME",
"ETLN.ME",
"TCSG.ME",
"ALRS.ME",
"VTBR.ME",
"FIVE.ME",
"QIWI.ME",
"LNTA.ME",
"RUAL.ME",
"ENPG.ME",
"BSPB.ME",
"POLY.ME",
"YNDX.ME",
"AFKS.ME",
"GAZP.ME",
"GMKN.ME",
"LSRG.ME",
"DSKY.ME",
"IRAO.ME",
"MVID.ME",
"MGNT.ME",
"MAGN.ME",
"MTLR.ME",
"MTLRP.ME",
"MTSS.ME",
"MOEX.ME",
"LKOH.ME",
"NLMK.ME",
"PIKK.ME",
"PLZL.ME",
"RSTI.ME",
"RSTIP.ME",
"RTKM.ME",
"RTKMP.ME",
"SFIN.ME",
"SBER.ME",
]

data = pd.DataFrame(columns = tickers_list)


for ticker in tickers_list:
    data[ticker] = yf.download(ticker,'2021-02-07','2021-02-09')['Adj Close']

data.head()
data.to_csv('RSI.csv')
print(round(data.head(),2))

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question