Skip to content

b1zmark1/CorrProgram

Repository files navigation

Correlation Explorer

Correlation Explorer is a Python application for exploring relationships between numeric columns in CSV and Excel datasets. It calculates correlation matrices, shows p-values where supported, renders an interactive heatmap, and exports the results in several formats.

Features

  • Load .csv, .xls, and .xlsx files.
  • Automatically select numeric columns for analysis.
  • Choose which columns should be included in the correlation matrix.
  • Handle missing values with drop, mean, median, zero, or a custom value.
  • Calculate Pearson, Spearman, Kendall, distance, and partial correlations.
  • Display correlation and p-value matrices.
  • Render a Plotly heatmap.
  • Export results to Excel, HTML, PNG, and PDF.

Tech Stack

  • Python
  • Streamlit
  • Tkinter
  • pandas
  • NumPy
  • SciPy
  • Pingouin
  • Plotly
  • Kaleido
  • XlsxWriter

Installation

Create and activate a virtual environment:

python -m venv .venv
.venv\Scripts\activate

Install dependencies:

pip install -r requirements.txt

Usage

Run the Streamlit version:

streamlit run app.py

Or run through the bundled launcher:

python run.py

Then open the local Streamlit URL in a browser, upload a dataset, choose the columns and correlation method, and build the matrix.

Desktop Version

The repository also contains a Tkinter-based desktop interface:

python tk-corr.py

This version provides a local desktop window for loading files, building the matrix, viewing the heatmap, and saving exported files.

Build

The project includes a PyInstaller spec file for creating a Windows executable:

pyinstaller "Correlation Explorer.spec"

The built application is generated in the dist directory.

Project Structure

.
|-- app.py
|-- run.py
|-- tk-corr.py
|-- utils.py
|-- requirements.txt
|-- Correlation Explorer.spec
`-- matrix-svgrepo-com.ico

Notes

  • PNG and PDF export require kaleido.
  • Partial and distance correlations use pingouin.
  • Only numeric columns are included in the analysis.

About

Python app for calculating correlation matrices from CSV/Excel data with Streamlit/Tkinter UI, Plotly heatmaps, p-values, missing-value handling, and export to XLSX, HTML, PNG, and PDF.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages