即使我有令牌访问权限,在不断收到错误“禁止”的情况下如何部署IEX API
import datetime as dt
import matplotlib.pyplot as plt
from matplotlib import style
import pandas as pd
import pandas_datareader.data as web
style.use('ggplot')
start = dt.datetime(2019, 1, 1)
end = dt.datetime.now()
df = web.DataReader("TSLA", 'iex', start, end,\n
access_key = <key>)
df.reset_index(inplace=True)
df.set_index("Date", inplace=True)
df = df.drop("Symbol", axis=1)
print(df.head())