Forums

ModuleNotFoundError: No module named 'Zipline'

getting errors while importing zipline

  #!/usr/local/bin/python3.6
  import pytz
  from datetime import datetime
  from Zipline.api import order, symbol, record, order_target
  from Zipline.algorithm import TradingAlgorithm
  from Zipline.utils.factory import load_bars_from_yahoo
  import pyexcel

Load data manually from Yahoo! finance

  start = datetime(2011, 1, 1, 0, 0, 0, 0, pytz.utc).date()
  end = datetime(2012,1,1,0,0,0,0, pytz.utc).date()

  data = load_bars_from_yahoo(stocks=['SPY'], start=start,end=end)

while running the above code the following error occurs

.Traceback (most recent call last): File "/home/veepsirtt/vpvp.py", line 4, in <module> from Zipline.api import order, symbol, record, order_target ModuleNotFoundError: No module named 'Zipline' zipline is already installed.How to fix it?.

how did you install it? was it installed into a virtualenv? or was it pip installed into say a different version of python? please provide the full error stack trace as well!

zipline pre installed

batteries

/home/veepsirtt/.local/lib/python3.6/site-packages/pandas/tseries/index.py:755: PerformanceWarning: Non-vectorized DateOffset being applied to Ser ies or DatetimeIndex PerformanceWarning) /home/veepsirtt/.local/lib/python3.6/site-packages/pandas/tseries/index.py:755: PerformanceWarning: Non-vectorized DateOffset being applied to Ser ies or DatetimeIndex PerformanceWarning) Traceback (most recent call last): File "/home/veepsirtt/vpvp.py", line 5, in <module> from Zipline.api import order, symbol, record, order_target ModuleNotFoundError: No module named 'Zipline'

How to upgrade zipline Version: 0.7.0 to zipline Version: 1.1.0? zipline 1.1.0 which has support for pandas 0.18.

Are you importing it correctly? Is Zipline the name of the module? It's much more likely to be zipline.

Zipline link description here

You might want to read the actual documentation instead of a random page on the internet.