Skip to content

No module named mplfinance in conda environment #99

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
damodar-basyal opened this issue Apr 18, 2020 · 5 comments
Closed

No module named mplfinance in conda environment #99

damodar-basyal opened this issue Apr 18, 2020 · 5 comments
Labels
question Further information is requested

Comments

@damodar-basyal
Copy link

I am trying to create ohlc graph. I have install mplfinance version 0.12.3a3 in conda environment using pip install. However, while running code in jupyter notebook, it says no module named mplfinance. How can i solve this issue?

@damodar-basyal damodar-basyal added the question Further information is requested label Apr 18, 2020
@DanielGoldfarb
Copy link
Collaborator

resolved via email

@MMSYYZ
Copy link

MMSYYZ commented Apr 20, 2020

Same here. How did you solve the issue?

@DanielGoldfarb
Copy link
Collaborator

DanielGoldfarb commented Apr 20, 2020

This is what I had sent to Damodar:

I am guessing that pip may have installed it in a place that your python sys.path does not include.

In general, with conda, you must first activate the conda environment into which you want to install mplfinance, and you must use the pip that is installed by conda in that environment. There are other ways that work but that is the usual one.

At this point you can try again as described above, or to figure out what went wrong you may want to examine sys.path from the jupyter notbook (compare with command line python just to confirm they are the same), and try to find where in the file system mplfinance got installed. More information on sys.path here: https://bic-berkeley.github.io/psych-214-fall-2016/sys_path.html

Let me know if that helps.


But apparently Damodar had found some issue with the jupyter setup ... that it was running under base or root instead of running under the same virtual environment that was intended (i.e. the same virtual environment into which mplfinance was installed).


Also, whenever i can't import something (package not found) from jupyter, i always then try a plain Python interpreter prompt to see if that works. And again, as was said above, make sure you are running jupyter or python in the same conda environment into which mplfinance was installed. All the best. --Daniel

@MMSYYZ
Copy link

MMSYYZ commented Apr 21, 2020 via email

@DanielGoldfarb
Copy link
Collaborator

Thanks. Good luck.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants