url NotFoundError with quandl

有些话、适合烂在心里 提交于 2020-02-16 05:13:27

问题


Code:

import pandas as pd

import quandl
quandl.ApiConfig.api_key = 'wsnt2aKcnkNMJjdqqwTz'

pd = quandl.get('BATS / BATS_GOOGL')

print(df.head())

Error:

NotFoundError: (Status 400) (Quandl Error QECx01) We could not recognize the URL you requested: /api/v3/datasets/BATS / BATS_GOOGL/data. Please check your URL and try again.


回答1:


You should not use spaces in the path; also, you should not use pd as a variable name (remember, you have imported pandas as pd), plus that, as is now, you are asking for the head() of a dataframe df that is nowhere defined.

Try with

df = quandl.get('BATS/BATS_GOOGL')


来源:https://stackoverflow.com/questions/58565534/url-notfounderror-with-quandl

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!