I have recently trying to use PyStan in Windows and found out it’s installation is more difficult than I thought. I normally use PyCharm as my IDE and was hopping to use PyStan with it. However, most advice I saw on the internet suggested I installed Anaconda instead, which I believe it comes with it’s onw IDE.
My question is: is it worth to learn how to work with Jupiter or Spider just for the sake of using PyStan? Should I try to find a way to incorporate both PyCharm and PyStan? Or should I try to call RStan (via subprocess for example) from python instead?
Thanks in advance!
PyStan needs mingw-w64 compiler and this is usually done with conda package manager which also install needed changes for python distutils.
You could link your PyCharm to conda env, but the problem is, that it is currently a bit broken, because user needs to call activation script to enable mingw.
See discussion in
Ps. I personally recommend
jupyter lab as an IDE
Alright, I installed Anaconda and following the windows instructions on the PyStan documentation to Windows and I managed to run PyStan in a conda environment.
I’m still trying to work around the problems surrounding PyCharm and PyStan as I’d really like to use PyCharm. However, I’m already trying out Juptyer Lab, thank you for the recommendation.
Thank you for your response!
@DjentMachine Did you resolve the issue? Are you able to use pystan on pycharm?
Will I be able to install pystan on pycharm at present without any issues?
you could also try using CmdStanPy instead of PyStan - it has fewer package dependencies.
@mitzimorris thanks. this works on pycharm as well? I’m so much used to the IDE, so asking
maybe I should try installing pystan first?
does the PyCharm IDE let you install packages from PyPi?
if so, install package cmdstanpy.
in the IDE, you should be able to install CmdStan on your machine via the
I haven’t used PyCharm, so I’d be interested to know if this works.
PyStan and CmdStanPy need to run in different virtual environments, and CmdStanPy requires Python3.
Pystan requires conda virtual environment right? I have been configuring that as of now
Hi, see this issue
10:57AM - 30 Sep 18 UTC
10:30AM - 15 Jul 19 UTC
I have tried to install PyStan using my Anaconda 5.0.0 following the instructions on the PyStan on Windows documentation here: https://pystan.readthedocs.io/en/latest/windows.html#windows
You need to make sure to activate your conda or adding special folders to PATH
@ahartikainen I am following that link.
Btw, regarding the the C++ compiler; do I have to install again for MacOS? I have installed it recently while installing rStan
Thanks. Yes, it did not ask me to install again
I just installed pystan. Actually it was straightforward. I used pip to install and I don’t think I used coda even though I configured the condo environment.
The 8 school example runs perfectly on pystan. This means stan is working properly?
I’m not sure if mingw-w64 was installed using Conda. but pystan is installed now and the 8schools examples is running successfully. This means mingw-w64 got installed?
Im on macOS Catalina. How do I check?
mingw is a Windows only thing. With a good compiler on macOS you don’t need conda. So everything looks good. (You can insert those to terminal)
Apple clang version 11.0.3 (clang-11##.0.32.29)
Thread model: posix
This is what I got