Issue
I've installed statsmodels
and it says "requirement already satisfied", but when I import it I get an error that the module doesn't exist.
conda update -n base -c defaults conda
pip install statsmodels
import statsmodel.api as sm
import yfinance as yf
import matplotlib.pyplot as plt
import datetime as dt
ModuleNotFoundError Traceback (most recent call last)
<ipython-input-9-07cc0a2ad076> in <module>
2 import matplotlib.pyplot as plt
3 import datetime as dt
----> 4 import statsmodel.api as sm
ModuleNotFoundError: No module named 'statsmodel'
What do I do?
Solution
The module is statsmodels
. See the documentation here.
So the correct way to call it is
import statsmodels.api as sm
Answered By - TC Arlen
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.