Scikit Learn is the popular python library for building a machine learning model. Its features are classification, regression, clustering algorithms. You can use it for data preprocessing, Hot encoding and many things using it. I have seen the new programmers who want to learn machine learning are unable to install Scikit learn properly. In this tutorial of “How to,” you will learn how to install Scikit Learn in Pycharm ? You have to just follow the simple steps for easy installation.
How to Check Scikit Learn is Installed or not?
If you write import sklearn you will see the underline with red color. It means that you have not installed scikit learn in Pycharm. Below are the steps you have to follow for the successful installation.
Steps to Install Scikit Learn in Pycharm
Step 1 : Go to File and Click on the Setting.
Step 2: There you will see the Project: your_project_name. Click on it and then project an interpreter.
Step 3: You will see all the list of installed packages in the current project. There you will not see scikit learn packages. You have to search and install it.
Step 4: Click on + icon right side of the step3 window and type scikit learn in the search window. When you get the scikit-learn package select it and click on install packages. It will successfully install the packages.
Step 5: If you are getting error like the below then the final step is to install the sklearn using the terminal .
Step 6: Go the terminal of the Pycharm and use the pip command to install the scikit learn.
pip install scikit-learn
It will successfully install the scikit- learn package in Pycharm.
How to test Installation of Scikit Learn ?
After the installation using the above steps To check whether scikit learn is installed or not. You can use the following code and run it.
import sklearn
print(sklearn.__version__)
Other Questions Asked by the Readers
Question: I am getting no module named sklearn error. How to solve this issue?
To solve this import error problem you have to install the scikit-learn python module. You can follow the above steps if you are installing in your Pycharm. But if you want to install using pip then use the following command.
pip install -U scikit-learn
It will update the existing sklearn module if available or install it if it is not available.
For the python 3.xx version use pip3
pip3 install -U scikit-learn
Join our list
Subscribe to our mailing list and get interesting stuff and updates to your email inbox.