Pandas and Polar DataFrames as interactive DataTables
Project description
This packages changes how Pandas and Polars DataFrames are rendered in Jupyter Notebooks.
With itables
you can display your tables as interactive DataTables
that you can sort, paginate, scroll or filter.
ITables is just about how tables are displayed. You can turn it on and off in just two lines, with no other impact on your data workflow.
The itables
package only depends on numpy
, pandas
and IPython
which you must already have if you work with Pandas in Jupyter (add polars
, pyarrow
if you
work with Polars DataFrames).
Documentation
Browse the documentation to see examples of Pandas or Polars DataFrames rendered as interactive DataTables.
Quick start
Install the itables
package with either
pip install itables
or
conda install itables -c conda-forge
Activate the interactive mode for all series and dataframes with
from itables import init_notebook_mode
init_notebook_mode(all_interactive=True)
and then render any DataFrame as an interactive table that you can sort, search and explore:
If you prefer to render only selected DataFrames as interactive tables, use itables.show
to show just one Series or DataFrame as an interactive table:
Since itables==1.0.0
, the jQuery and DataTables libraries and CSS
are injected in the notebook when you execute init_notebook_mode
with its default argument connected=False
.
Thanks to this the interactive tables will work even without a connection to the internet.
If you prefer to load the libraries dynamically (and keep the notebook lighter), use connected=True
when you
execute init_notebook_mode
.
Supported environments
ITables works in all the usual Jupyter Notebook environments, including Jupyter Notebook, Jupyter Lab, Jupyter nbconvert (i.e. the tables are still interactive in the HTML export of a notebook), Jupyter Book, Google Colab and Kaggle.
You can also use ITables in Quarto HTML documents, and in RISE presentations.
ITables works well in VS Code, both in Jupyter Notebooks and in interactive Python sessions.
Last but not least, ITables is also available in Streamlit or Shiny applications.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file itables-2.1.5.tar.gz
.
File metadata
- Download URL: itables-2.1.5.tar.gz
- Upload date:
- Size: 2.3 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ed96c98cdd91a91c004c1a0150d572a6b1021a1311bc94e8bfa2e68ba42d44fb |
|
MD5 | ab5671cc24d6cbcd5cefc1f4da0f3784 |
|
BLAKE2b-256 | 7a44d87ae1ec76332ef15dd80916c73d58f677b92e7234bcb1678b356ea9fc43 |
File details
Details for the file itables-2.1.5-py3-none-any.whl
.
File metadata
- Download URL: itables-2.1.5-py3-none-any.whl
- Upload date:
- Size: 1.2 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.5
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 842e7e31f3f6ea5e4a085d189dcb6ee38e20c0750e4322a31eccb895e5a00a76 |
|
MD5 | bf931597ae420af964028c5d97b8a385 |
|
BLAKE2b-256 | cb4d3cfc3601973ce25eaaaf24dd7dc1bd1e2c6290f9a3621060cfbde7b91f87 |