pmorissette / ffn

ffn - a financial function library for Python
pmorissette.github.io/ffn
MIT License
1.97k stars 294 forks source link

import error #9

Closed jdkcupid closed 7 years ago

jdkcupid commented 9 years ago

I use the

ffn                       0.1.9                     <pip>

I try to import ffn

import ffn

Then it shows the error

In [1]: import ffn
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-1-30624921af03> in <module>()
----> 1 import ffn

/opt/anaconda/envs/py27matt/lib/python2.7/site-packages/ffn/__init__.py in <module>()
----> 1 from . import core
      2 from . import data
      3
      4 from .data import get
      5 #from .core import year_frac, PerformanceStats, GroupStats, merge

/opt/anaconda/envs/py27matt/lib/python2.7/site-packages/ffn/core.py in <module>()
      1 from __future__ import print_function
----> 2 from future.utils import listvalues
      3 import random
      4 from . import utils
      5 from .utils import fmtp, fmtn, fmtpn, get_period_name

ImportError: No module named future.utils
pmorissette commented 9 years ago

Hey @jdkcupid,

I think you need to install the future library:

pip install future

This requirement was added in order to support Python3. I'll try to fix this so that it gets installed automatically with ffn.

Cheers, Phil