Installing scikit-plots#

Scikit-plots relies on Matplotlib and Scikit-learn for plotting model results. Additionally, it can work with results from other modeling libraries such as TensorFlow and PyTorch. Ensure that you have the necessary libraries installed in your environment.

There are different ways to install scikit-plots:

Installing the latest release#

Install the 64-bit version of Python 3, for instance from the official website.

Now create a virtual environment (venv) and install scikit-plots. Note that the virtual environment is optional but strongly recommended, in order to avoid potential conflicts with other packages.

python -m venv sklearn-env
sklearn-env\Scripts\activate  # activate
pip install -U scikit-plots

In order to check your installation, you can use:

python -m pip show scikit-plots  # show scikit-plots version and location
python -m pip freeze             # show all installed packages in the environment
python -c "import scikitplot; scikitplot.show_versions()"

Python 3 is usually installed by default on most Linux distributions. To check if you have it installed, try:

python3 --version
pip3 --version

If you don’t have Python 3 installed, please install python3 and python3-pip from your distribution’s package manager.

Now create a virtual environment (venv) and install scikit-plots. Note that the virtual environment is optional but strongly recommended, in order to avoid potential conflicts with other packages.

python3 -m venv sklearn-env
source sklearn-env/bin/activate  # activate
pip3 install -U scikit-plots

In order to check your installation, you can use:

python3 -m pip show scikit-plots  # show scikit-plots version and location
python3 -m pip freeze             # show all installed packages in the environment
python3 -c "import scikitplot; scikitplot.show_versions()"

Install Python 3 using homebrew (brew install python) or by manually installing the package from the official website.

Now create a virtual environment (venv) and install scikit-plots. Note that the virtual environment is optional but strongly recommended, in order to avoid potential conflicts with other packges.

python -m venv sklearn-env
source sklearn-env/bin/activate  # activate
pip install -U scikit-plots

In order to check your installation, you can use:

python -m pip show scikit-plots  # show scikit-plots version and location
python -m pip freeze             # show all installed packages in the environment
python -c "import scikitplot; scikitplot.show_versions()"

Warning

Not Implemented…

Install conda using the miniforge installers (no administrator permission required). Then run:

conda create -n sklearn-env -c conda-forge scikit-plots
conda activate sklearn-env

In order to check your installation, you can use:

conda list scikit-plots  # show scikit-plots version and location
conda list               # show all installed packages in the environment
python -c "import scikitplot; scikitplot.show_versions()"

Setting Up Your Environment#

To manage dependencies and avoid conflicts, it is recommended to use an isolated environment, such as pip venv or conda. This approach allows you to install specific versions of scikit-learn and its dependencies independently from other Python packages.

For Linux users, it is advisable to avoid installing pip packages alongside those managed by your distribution’s package manager (e.g., apt, dnf, pacman).

Activating Your Environment#

Remember to activate your chosen environment before running any Python commands, especially when starting a new terminal session.

Installing Dependencies#

If you have not yet installed NumPy or SciPy, you can do so using pip or conda. When using pip, ensure that binary wheels are used to avoid compiling from source. This is particularly important for certain configurations, such as running Linux on a Raspberry Pi.