economia
economia

Reputation: 61

How to install fbprophet for Python 3.7 (anaconda distribution)

I attempted to use fbprophet for time series analysis using Python.

I ran from fbprophet import Prophet but got No module named 'fbprophet'

I think fbprophet is not part of packages that comes with anaconda distribution

I went ahead to install fbprophet but got this error message No module named 'fbprophet'

I am on Windows 10, 64 bits

I install anaconda distribution of anaconda 3.7

I have ran conda install -c conda-forge fbprophet and conda install -c conda-forge/label/cf201901 fbprophet on my anaconda prompt which it rolled endlessly

I have also ran pip install fbprohet which did not work as well

I ran pip list which worked but prophet or fbprophet not among the list

I have searched this site for relevant questions and tried all what I clues I got in it but did not work for me.

Upvotes: 6

Views: 27945

Answers (8)

Prat13k
Prat13k

Reputation: 31

First install

    pip install httpstan`

Then Install

    pip install pystan

Then Install

    pip install fbprophet

Upvotes: 1

Lorenzo Bassetti
Lorenzo Bassetti

Reputation: 935

Use conda install gcc to set up gcc. The easiest way to install Prophet is through conda-forge: conda install -c conda-forge prophet.

Upvotes: 0

Dong Wang
Dong Wang

Reputation: 1

fbprophet did not work on Python 3.9 It is a very important information, after downgrading Python from 3.9 to 3.8, I use 'conda install fbprophet' install fbprophet successfully

Upvotes: 0

Sarvavyapi
Sarvavyapi

Reputation: 850

I had the same issue, but none of the answers mentioned here worked (Windows 10 machine). What worked was the following:

conda config --add channels conda-forge
conda install anaconda 

Above step took almost 25 hours for me. Do above only if you get this error "The environment is inconsistent, please check the package plan carefully"

pip install pystan==2.19.1.1
conda install python=3.8 (fbprophet did not work on Python 3.9)
conda install numpy=1.19.0
conda install fbprophet=0.7.1

Upvotes: 1

Radhika Shenoy
Radhika Shenoy

Reputation: 33

You can check this official github link where the detailed steps for installation is given. This library is supported only in Python 3.

Open cmd, run this command -

pip install pystan==2.19.1.1

Then run this-

pip install prophet

Upvotes: 1

Matthew Fedoseev
Matthew Fedoseev

Reputation: 29

I installed this way:

pip install pystan==2.19.1.1

then:

pip install prophet

It seems that currently pystan version 3 is not working properly. (Tested on MacOS)

Upvotes: 1

Gonçalo Peres
Gonçalo Peres

Reputation: 13582

Option 1

conda install -n [NameOfVEnv] -c conda-forge fbprophet

Where -c stands for "channel" which is

the locations where Navigator and conda look for packages. (Source)

and -n for "Name of environment".

I just tried here (on CentOS 7) and it worked fine.


Option 2

An alternative, if one is using Windows 10, is to access Anaconda Prompt for the environment that you are working with as admin:

Access Anaconda Prompt as admin

And run

conda install -c conda-forge fbprophet

I just tried here (on Windows 10 64-bit) and it worked fine.


Option 3

Prophet is on PyPI, so you can use pip to install it (Source)

# bash
# Install pystan with pip before using pip to install fbprophet
$ pip install pystan
$
$ pip install fbprophet

You may need to install dependencies (in both options), but it asks you in the prompt window. If it appears, you will need to enter Y.

Upvotes: 5

Tom.chen.kang
Tom.chen.kang

Reputation: 183

you just search the wrong letter, please enter pip search fbprophet,in the way, i can get two

Upvotes: 0

Related Questions