Skip to main content

Vertical summary statistics for data frames

Project description

showstats: quick and compact summary statistics

showstats produces summary statistic tables with vertical orientation.

from showstats import show_stats

show_stats(df)
| Var.          | Null % | Mean          | Median        | Std.     | Min           | Max          |
| N=1.00E+6     |        |               |               |          |               |              |
|---------------|--------|---------------|---------------|----------|---------------|--------------|
| float_mean_2  | 0%     | 2.0           | 2.0           | 1.0      | -2.6          | 6.6          |
| float_std_2   | 0%     | 0.0013        | 0.00024       | 2.0      | -9.3          | 9.3          |
| float_min_7   | 0%     | 12.0          | 12.0          | 1.0      | 7.0           | 16.0         |
| float_max_17  | 0%     | 12.0          | 12.0          | 1.0      | 7.7           | 17.0         |
| bool_col      | <40%   | 0.5           | 0.0           | 0.5      | 0.0           | 1.0          |
| int_col       | 0%     | 500000.0      | 500000.0      | 290000.0 | 0.0           | 1000000.0    |
| float_col     | 0%     | 5000.0        | 5000.0        | 2900.0   | 0.0           | 10000.0      |
| U             | 0%     | 0.5           | 0.5           | 0.29     | 5.1e-7        | 1.0          |
| int_with_miss | <20%   | 500000.0      | 500000.0      | 290000.0 | 1.0           | 1000000.0    |
| ings          |        |               |               |          |               |              |
| datetime_col  | 0%     | 1750-01-30    | 1750-03-18    |          | 1500-01-01    | 1999-12-31   |
|               |        | 01:54:50      | 04:52:16      |          | 04:17:28      | 21:39:20     |
| datetime_col_ | 0%     | 1750-01-12    | 1750-01-22    |          | 1500-01-01    | 1999-12-31   |
| 2             |        | 23:02:09      | 06:33:24      |          | 06:19:48      | 17:41:57     |
| date_col      | 0%     |               |               |          | 1500-01-01    | 1999-12-31   |
| date_col_2    | 0%     |               |               |          | 1500-01-01    | 1999-12-31   |
| str_col       | <60%   |               |               |          | ABC           | foo          |
| enum_col      | 0%     |               |               |          | worst         | best         |
| categorical_c | 0%     |               |               |          | Fara          | Car          |
| ol            |        |               |               |          |               |              |
| null_col      | 100%   |               |               |          |               |              |

Primarily built for polars data frames, showstats converts other inputs. For full compatibility with pandas.DataFrames install as pip install showstats[pandas].

Because showstats uses polars as backend, its really fast: <1 second for a 1,000,000 × 1,000 data frame, running on a M1 MacBook.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

showstats-0.0.2.tar.gz (18.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

showstats-0.0.2-py3-none-any.whl (6.6 kB view details)

Uploaded Python 3

File details

Details for the file showstats-0.0.2.tar.gz.

File metadata

  • Download URL: showstats-0.0.2.tar.gz
  • Upload date:
  • Size: 18.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.19

File hashes

Hashes for showstats-0.0.2.tar.gz
Algorithm Hash digest
SHA256 3515883a5577d27dc3d940b93e51b98a9bedb5755834ac29e3d8f1aca35b1b73
MD5 ea377ec8e1ff8ce761230ba55bb68edc
BLAKE2b-256 31e25f38368681d321362fe5820c88a707cbc553ee02fc2cbbbc6944c8699085

See more details on using hashes here.

File details

Details for the file showstats-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: showstats-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 6.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.8.19

File hashes

Hashes for showstats-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4be8576c020e7ca6c0010f9ae9ee776babe24ce9095f29214404be3c1f2fb253
MD5 71a0b6c5f7b04bd7421ba5b23d520cdb
BLAKE2b-256 5deadd3b32255dbf06f1a754b6069f41baccbf92279d3e819ebb1e4e5ee05bdb

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page