Skip to main content

DataComPy

PyPI - Python Version Ruff PyPI version Anaconda-Server Badge PyPI - Downloads

DataComPy is a package to compare two DataFrames (or tables) such as Pandas, Spark, Polars, and even Snowflake. Originally it was created to be something of a replacement for SAS's PROC COMPARE for Pandas DataFrames with some more functionality than just Pandas.DataFrame.equals(Pandas.DataFrame) (in that it prints out some stats, and lets you tweak how accurate matches have to be). Supported types include:

  • Pandas
  • Polars
  • Spark
  • Snowflake (via snowpark)
  • Dask (via Fugue)
  • DuckDB (via Fugue)

Quick Installation

pip install datacompy

or

conda install datacompy

Installing extras

If you would like to use Spark or any other backends please make sure you install via extras:

pip install datacompy[spark]
pip install datacompy[fugue]
pip install datacompy[snowflake]

LegacySparkCompare and SparkPandasCompare removal

Starting with v0.17.0, both LegacySparkCompare and SparkPandasCompare have been removed.

Supported versions and dependencies

Different versions of Spark, Pandas, and Python interact differently. Below is a matrix of what we test with. With the move to Pandas on Spark API and compatability issues with Pandas 2+ we will for the mean time note support Pandas 2 with the Pandas on Spark implementation. Spark plans to support Pandas 2 in Spark 4

Spark 3.4.4 Spark 3.5.6
Python 3.10 ✅ ✅
Python 3.11 ✅ ✅
Python 3.12 ❌ ❌
Pandas < 1.5.3 Pandas >=2.0.0
Compare ✅ ✅
SparkSQLCompare ✅ ✅
Fugue ✅ ✅

[!NOTE] At the current time Python 3.12 is not supported by Spark and also Ray within Fugue. If you are using Python 3.12 and above, please note that not all functioanlity will be supported. Pandas and Polars support should work fine and are tested.

Supported backends

  • Pandas: (See documentation)
  • Spark: (See documentation)
  • Polars: (See documentation)
  • Snowflake/Snowpark: (See documentation)
  • Fugue is a Python library that provides a unified interface for data processing on Pandas, DuckDB, Polars, Arrow, Spark, Dask, Ray, and many other backends. DataComPy integrates with Fugue to provide a simple way to compare data across these backends. Please note that Fugue will use the Pandas (Native) logic at its lowest level (See documentation)

Contributors

We welcome and appreciate your contributions! Before we can accept any contributions, we ask that you please be sure to sign the Contributor License Agreement (CLA).

This project adheres to the Open Source Code of Conduct. By participating, you are expected to honor this code.

Roadmap

Roadmap details can be found here

Metadata

Release files for datacompy 0.18.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for datacompy 0.18.0
File Size Uploaded
datacompy-0.18.0.tar.gz 92.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for datacompy 0.18.0
File Interpreter ABI Platform
datacompy-0.18.0-py3-none-any.whl Python 3 none any Details

Total release size: 158.2 kB

Release files / datacompy-0.18.0.tar.gz

Download URL datacompy-0.18.0.tar.gz
Size 92.0 kB
Tags Source
SHA-256 checksum
How to use checksums
22a13709aa9702760ca5cf6c200aa6fd44a1361224b6eba250ced1a51de71af7
BLAKE2b-256 checksum
How to use checksums
e9b8c9df54f69723a3958573f60cff79e0e097442435d665c9b43a634a3e5072
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.10.18

Release files / datacompy-0.18.0-py3-none-any.whl

Download URL datacompy-0.18.0-py3-none-any.whl
Size 66.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
39bb5b55ab28d2bac2d379583d049b87d784c54f131db004c7315139cf38b296
BLAKE2b-256 checksum
How to use checksums
e83fcbe2436a553847d10ac7058372002b1dfb534370e54505add51041a4122c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.10.18

Release history Release notifications | RSS feed

1.1.0

2 release files

1.0.4

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

0.19.4

2 release files

0.19.3

2 release files

0.19.1

2 release files

0.19.0

2 release files

This release

0.18.0 This release

2 release files

0.17.1

2 release files

0.16.8

2 release files

0.16.7

2 release files

0.16.6

2 release files

0.16.5

2 release files

0.16.4

2 release files

0.16.3

2 release files

0.16.2

2 release files

0.16.0

2 release files

0.15.0

2 release files

0.14.3

2 release files

0.14.2

2 release files

0.14.1

2 release files

0.14.0

2 release files

0.13.3

2 release files

0.13.2

2 release files

0.13.1

2 release files

0.13.0

2 release files

0.12.1

2 release files

0.11.3

2 release files

0.11.2

2 release files

0.11.1

2 release files

0.11.0

2 release files

0.10.5

2 release files

0.10.4

2 release files

0.10.3

2 release files

0.10.2

2 release files

0.9.0

2 release files

0.8.4

2 release files

0.8.3

2 release files

0.8.2

2 release files

0.8.1

2 release files

0.8.0

2 release files

0.7.3

2 release files

0.7.2

2 release files

0.7.1

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.2

2 release files

0.5.1

1 release file

0.5.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page