Forum Discussion
how to install modules
Hi StacyBell2021 ,
Please try:
1. Please install all the packages that you are mentioning in the python script in Power BI, explicitly in Command Prompt.
Open Command Prompt > for example, type in " py -m pip install pandas" without quotes and then try running the py script in Power BI.
2. This could be because the Python installation directory is not added to the system's PATH environment variable.
You can use the command to add pip to your PATH variable from the command promptsetx.
For example, if your Python version is 3.9, you can type:
setx PATH "%PATH%;C:\Python39\Scripts"
3.Open the Anaconda Prompt or Command Prompt as an administrator.
cd C:\Python\
python -m pip install pandas
python -m pip install matplotlib
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
How do I find where python is installed
- Anonymous2 years agoNot applicable
Hi StacyBell2021 ,
You can find out where Python is installed on your Windows machine by following these steps:
1. Type Python in the Windows Search Bar.
2. Right-click on the Python App, and then select “Open file location” .
3. Right-click again on the Python shortcut, and then select “Properties”.
4. You’ll now get the location/path where your Python is installed on Windows .Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.