Visidata is a powerful terminal-based tool for working with tabular data. It allows for quick data analysis, filtering, and transformation with minimal resource usage. Learn more about it here.

Since Visidata is a cross-platform application, there are many ways to install it. I recommend installing it as a pip package for your primary global Python interpreter. This provides flexibility in managing additional packages and dependencies that Visidata might require for certain use cases.


Installing Visidata on macOS/Linux

Step 1: Ensure Python is Installed

Visidata is distributed as a Python package, so you’ll need Python version 3.7 or higher (preferably later for the latest features). To check your Python version, run:

python3 --version

If Python is not installed, you can install it using your system’s package manager:

macOS:

Install Homebrew (if it’s not already installed), then run:

brew install python

Linux:

For most Linux distributions, Python can be installed via the default package manager. Here’s how for popular distributions:

  • Ubuntu/Debian:
sudo apt update  
sudo apt install python3 python3-pip
  • Fedora:
sudo dnf install python3 python3-pip
  • Arch Linux/Manjaro:
sudo pacman -S python python-pip
  • CentOS/RHEL:

For CentOS/RHEL 8 and later:

sudo dnf install python3 python3-pip

For older versions like CentOS 7, you may need to enable the EPEL repository:

sudo yum install epel-release  
sudo yum install python3 python3-pip

If your distribution is not listed, consult its official documentation or compile Python from source.


Step 2: Install Visidata via pip

Once Python is installed, you can use pip to install Visidata. Run:

pip install visidata --upgrade

This installs the latest version of Visidata.


Step 3: Verify Installation

After installation, confirm that Visidata works correctly by running:

vd --version

If the command is not recognized, it could mean the directory where pip installed Visidata is not in your PATH environment variable. To fix this:

  1. Find the directory where pip installed packages. Run:
which python3
  1. Ensure the bin directory inside this path is added to your PATH. For macOS/Linux, it might look like this:
export PATH="/opt/homebrew/bin/python3/bin:$PATH"
  1. Add this line to your shell configuration file (~/.bashrc, ~/.zshrc, or another, depending on your shell) to make it persistent. Reload the configuration with:
source ~/.bashrc  # For bash  
source ~/.zshrc   # For zsh
  1. Retry the command:
vd --version

If the issue persists, reinstall Visidata with the --user flag:

pip install --user visidata --upgrade

Step 4: Install Additional Dependencies

Visidata uses various Python libraries for extended functionality. To enhance its capabilities, install the following:

pip install PyYAML lxml pandas xlrd openpyxl h5py xport savReaderWriter --upgrade

These libraries enable Visidata to handle files like Excel, YAML, HDF5, XML, XPT, SAV, Arrow, and HTML tables.

Additionally, install the tabulate library to export data as beautiful tables:

pip install tabulate --upgrade

Supported table formats are detailed in the tabulate documentation.


Installing Visidata on Windows

Step 1: Ensure Python is Installed

On Windows, you’ll also need Python 3.7 or higher. To check, run in Command Prompt or PowerShell:

python --version

If Python is not installed, download it from python.org and install it. During installation, ensure you check “Add Python to PATH” for easier access.


Step 2: Install Visidata via pip

With Python installed, run the following in Command Prompt or PowerShell:

pip install visidata --upgrade

This installs the latest version of Visidata.


Step 3: Verify Installation

Check that Visidata works by running:

vd --version

If the command is unrecognized, it might be because the Scripts directory (where pip installs executables) is not in your PATH. To fix this:

  1. Locate the Scripts directory, typically:
C:\Users\<Your_Username>\AppData\Local\Programs\Python\Python<version>\Scripts\
  1. Add this path to your PATH environment variable:

    • Press Win + S and search for “Environment Variables.”
    • Under “System Variables,” find Path and click “Edit.”
    • Add the Scripts directory path.
  2. Restart Command Prompt and check again:

vd --version

If it still doesn’t work, reinstall Visidata with the --user flag:

pip install --user visidata --upgrade

Step 4: Install Additional Dependencies

Enhance Visidata’s functionality by installing additional libraries:

pip install PyYAML lxml pandas xlrd openpyxl h5py xport savReaderWriter --upgrade

Also, install tabulate for exporting data in various table formats:

pip install tabulate --upgrade

Refer to the tabulate documentation for supported formats.


Now you’re ready to use Visidata for data analysis! For any issues during installation, check the official documentation.