在Python 3.7中使用IEX

时间:2019-01-30 18:18:49

标签: python for-loop using stocks iex

我的代码是:

import numpy as np
from datetime import datetime
import smtplib
import time
from selenium import webdriver
#For Prediction
from sklearn.linear_model import LinearRegression
from sklearn import preprocessing, svm
#For Stock Data
from iex import Stock
import iex

tsla = Stock('TSLA')
tsla.get_price()

我的错误是:

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-47-6b00c609b0e7> in <module>
     11 import iex
     12 
---> 13 tsla = Stock('TSLA')
     14 tsla.get_price()

TypeError: __init__() takes 1 positional argument but 2 were given

0 个答案:

没有答案