Skip to main content

Extra widgets for Jupyter Lab

Project description

labext

PyPI Python GitHub Issues Contributions welcome License

Overview

This library provides pre-built widgets and integrates some additional JS libraries to provide an even better experience to work with data in Jupyter Lab.

Features:

  1. Better display for pandas data frame.
  2. Pop-over content, allowing to show additional content when hovering over a DOM element.
  3. Widgets for interactive labeling/annotating data in Jupyter Lab.

Usage

See the Demo notebook for how to use the library. Demo:

  1. Converting DataFrame to DataTable
    DataTable

  2. Pop-over (Tippy)
    Tippy

  3. Slider
    Slider

  4. Annotator
    Annotator

Installation

Docker

I provide a Dockerfile that create a base environment to run this library. To run the demo notebook in docker, you can use docker-compose to start a jupyter lab:

docker-compose up

Manual

To use this with JupyterLab, you need to have requirejs enable in Jupyter by installing either:

  1. https://github.com/DraTeots/jupyterlab_requirejs (jupyterlab version <= 1.*)
  2. https://github.com/binh-vu/jupyterlab_requirejs (jupyterlab version >= 2.*)

Beside requirejs, you also need to have ipywidgets, ipyevents, ipycallback

pip install ipywidgets ipyevents ipycallback
jupyter nbextension enable --py widgetsnbextension
jupyter nbextension enable --py --sys-prefix ipyevents
jupyter labextension install @jupyter-widgets/jupyterlab-manager ipyevents ipycallback

Finally, install this package directly from pypi:

pip install -U labext

Development

To compile the typescript files you need to install:

npm install @types/jquery

Then compiles all .ts files, remove--watch if you don't want to monitor for changes.

tsc --target es2017 --watch **/*.ts

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

labext-4.1.6.tar.gz (397.9 kB view details)

Uploaded Source

File details

Details for the file labext-4.1.6.tar.gz.

File metadata

  • Download URL: labext-4.1.6.tar.gz
  • Upload date:
  • Size: 397.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/45.2.0.post20200210 requests-toolbelt/0.9.1 tqdm/4.42.1 CPython/3.7.6

File hashes

Hashes for labext-4.1.6.tar.gz
Algorithm Hash digest
SHA256 c22038e309ca71b616d8e4b5b9405e9b967321037adabf8e4c4fe58923fafbfb
MD5 46391349702fc073745e110b54d7e292
BLAKE2b-256 3cf3830b25b264fefc19354f850fe346a77f17b58014c8b1eb8fb7f4ad357f3f

See more details on using hashes here.

Supported by

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