pip install fbprophet 으로 설치가 안될때
python -m pip install prophet 으로 설치하고. fbprophet을 prophet으로 바꾸어 준다.
pip install -U finance-datareader
pip install plotly
from prophet import Prophet
from prophet.plot import plot_plotly, plot_components_plotly
import FinanceDataReader as fdr
StockCode = '247540'
stock = fdr.DataReader(StockCode, '2021-1-1')
stock.head()
stock['y'] = stock['Close']
stock['ds'] = stock.index
stock.head()
m = Prophet()
m.fit(stock)
feature = m.make_future_dataframe(periods=30)
forecast = m.predict(feature)
fig = m.plot(forecast)
하고 나면
ValueError: Mime type rendering requires nbformat>=4.2.0 but it is not installed ->
에러가 나온다
pip install nbformat
pip install --upgrade nbformat
한후
pip install ipykernel
커널을 다시설치하고, Reset kernel을 한다.
댓글 없음:
댓글 쓰기