The main difference between PyCharm and Anaconda is that PyCharm is a quite convenient IDE and Anaconda is a set of python libraries. What I can recommend you right now: (do it in your terminal (โ+space -> terminal) or in PyCharm's terminal):
pip3 install numpy
The error you show seems like you tried to run it not in the terminal, but in python's console box :/
Also - here is a nice way to connect Anaconda's libraries to PyCharm
For installing libraries via PyCharm preferences:
1. Click on the "PyCharm" -> "Preferences"
2. Click on "Project Interpreter" and go for "+" button 
3. Type "numpy" and "install package"
The main difference between PyCharm and Anaconda is that PyCharm is a quite convenient IDE and Anaconda is a set of python libraries. What I can recommend you right now: (do it in your terminal (โ+space -> terminal) or in PyCharm's terminal):
pip3 install numpy
The error you show seems like you tried to run it not in the terminal, but in python's console box :/
Also - here is a nice way to connect Anaconda's libraries to PyCharm
For installing libraries via PyCharm preferences:
1. Click on the "PyCharm" -> "Preferences"
2. Click on "Project Interpreter" and go for "+" button 
3. Type "numpy" and "install package"
Try this way:
1:
Pycharm Preferences => Phyton interpreter
2:
Select Project interpreter
3:
Select the add button ( + )
4:
in search bar search for numpy
5:
Install package.
If you still got errors
No module named 'numpy'
Then go to Terminal left bottom corner of PyCharm software.
Then install numpy.
pip install numpy
Help With NumPy (Installation)
macos - How to install numpy with PyCharm on mac OSX? - Stack Overflow
python - Import NumPy on PyCharm - Stack Overflow
Unable to install numpy in pycharm version 9.3.3. Python version 3.8.2
How do I install NumPy in a PyCharm virtual environment?
How do I install NumPy in PyCharm using pip?
How do I check if NumPy is installed in PyCharm?
UPDATE: Problem fixed. Thanks for the help, everyone.
For those having the same issue: My problem was that the virtual environment in PyCharm was preventing me from accessing my installation of numpy. If you are using PyCharm, be sure to use the in-built menus to install numpy from within the app (tutorial linked by someone in the comments below)!
Hello all,
I have been having some troubles attempting to install and use the NumPy module. I would like to create some arrays/matrices to use in the project I am working on. However, I cannot seem to get it to work...
So I looked it up, apparently I managed to grab a Python package that does not already have NumPy. That's fine, I can install it myself. But when I tried to type pip install numpy, it gives me the following error message (I tried just typing pip, pip install, but nothing seems to work):
Python 3.9.13 (tags/v3.9.13:6de2ca5, May 17 2022, 16:36:42) [MSC v.1929 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> pip
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'pip' is not defined
>>> pip install
File "<stdin>", line 1
pip install
^
SyntaxError: invalid syntax
>>> pip install numpy
File "<stdin>", line 1
pip install numpy
^
SyntaxError: invalid syntax
>>>
I did some looking around on google, and found someone who said to try importing pip before attempting the install, and so I did just that in my python cmd window (this is the python shell that I can launch from my start menu, but I have also tried this on the regular windows cmd window), et voila, it installed it. Problem solved, or so it seemed...
So I then go to try and use import numpy and even from numpy import * in my script in PyCharm, but I get the following messages:
"No module named numpy" or "Unresolved reference 'numpy'."
What gives? Now, I will say that there seems to be something up with my PATH, because if I type py into my Windows cmd window, python loads up, but if I type out python, it pulls up the windows store. I remember that the shell said something about the PATH while "installing" numpy, but I didn't think anything of it because it still completed the installation, so I did not copy down the exact message.
Any help would be appreciated. I feel like it's something to do with the PATH stuff, or I somehow messed up my original python installation. But everything else works fine, I've been writing code for the past four days with no issues.
I ran into the same problem. And I solved it like this: File/Default Settings...
Chose Default Project/Project Interpreter
Chose the version of Python you are working with from the popup menu Project Interpreter.
Below the list click on the '+' button. Find your way in the huge list of Packages available to find 'numpy' and install it.
There is probably another way to make it per project, but I assume that you want numpy in all project (it is my case).
You drag it to wherever you want it... There's no step 2, much less step 3.
Go to
- ctrl-alt-s
- click "project:projet name"
- click project interperter
- double click pip
- search numpy from the top bar
- click on numpy
- click install package button
if it doesnt work this can help you:
https://www.jetbrains.com/help/pycharm/installing-uninstalling-and-upgrading-packages.html
In PyCharm go to
- File โ Settings, or use Ctrl + Alt + S
- < project name > โ Project Interpreter โ gear symbol โ Add Local
- navigate to
C:\Miniconda3\envs\my_env\python.exe, where my_env is the environment you want to use
Alternatively, in step 3 use C:\Miniconda3\python.exe if you did not create any further environments (if you never invoked conda create -n my_env python=3).
You can get a list of your current environments with conda info -e and switch to one of them using activate my_env.