Awesome
<p align="center"> <img src="docs/img/logo.png" width=200></img> </p> <p align="center"> <a href="https://github.com/finos/ipyregulartable/actions?query=workflow%3A%22Build+Status%22"><img alt="Build Status" src="https://github.com/finos/ipyregulartable/workflows/Build%20Status/badge.svg?branch=main"></a> <a href="https://codecov.io/gh/finos/ipyregulartable"><img alt="Coverage" src="https://codecov.io/gh/finos/ipyregulartable/branch/main/graph/badge.svg"></a> <a href="https://pypi.python.org/pypi/ipyregulartable"><img alt="PyPI Version" src="https://img.shields.io/pypi/v/ipyregulartable.svg?color=brightgreen&style=flat-square"></a> <a href="https://www.npmjs.com/package/ipyregulartable"><img alt="NPM Version" src="https://img.shields.io/npm/v/ipyregulartable.svg?color=brightgreen&style=flat-square"></a> <a href="https://github.com/finos/ipyregulartable"><img alt="License" src="https://img.shields.io/github/license/finos/ipyregulartable?color=brightgreen&style=flat-square"></a> <a href="https://community.finos.org/docs/governance/software-projects/stages/incubating"><img alt="FINOS Incubating" src="https://cdn.jsdelivr.net/gh/finos/contrib-toolbox@master/images/badge-incubating.svg"></a> <a href="https://mybinder.org/v2/gh/finos/ipyregulartable/main?urlpath=lab"><img alt="Binder" src="https://mybinder.org/badge_logo.svg"></a> </p>An ipywidgets wrapper of regular-table for Jupyter.
Examples
Two Billion Rows
Click Events
Edit Events
Styling
Pandas Data Model
For interactive/streaming sorting/pivoting/aggregation, take a look at Perspective, Streaming pivot visualization via WebAssembly, which also leverages regular-table
.
Series
DataFrame
DataFrame - Row Pivots
DataFrame - Column Pivots
DataFrame - Pivot Table
Installation
PyPI
ipyregulartable
is available on PyPI:
pip install ipyregulartable
Conda
ipyregulartable
is also available on conda-forge:
conda install -c conda-forge ipyregulartable
Jupyter Server/JupyterLab Extension
jupyter labextension install ipyregulartable
jupyter serverextension enable --py ipyregulartable
If you are using Jupyter Notebook 5.2 or earlier, you may also need to enable the nbextension:
jupyter nbextension enable --py [--sys-prefix|--user|--system] ipyregulartable
Data Model
It is very easy to construct a custom data model. Just implement the abstract methods on the base DataModel
class.
class DataModel(with_metaclass(ABCMeta)):
@abstractmethod
def editable(self, x, y):
'''Given an (x,y) coordinate, return if its editable or not'''
@abstractmethod
def rows(self):
'''return total number of rows'''
@abstractmethod
def columns(self):
'''return total number of columns'''
@abstractmethod
def dataslice(self, x0, y0, x1, y1):
'''get slice of data from (x0, y0) to (x1, y1) inclusive'''
Any DataModel
object can be provided as the argument to RegularTableWidget
. Note that regular-table
may make probing calls of the form (0, 0, 0, 0) to assess data limits.
Development
See CONTRIBUTING.md for guidelines.
License
This software is licensed under the Apache 2.0 license. See the LICENSE and AUTHORS files for details.