Skip to main content

Wrapper around the LineUp.js library for multi attribute rankings

Project description

LineUp.js as Jupyter Widget

License: MIT CircleCI CircleCI

LineUp is an interactive technique designed to create, visualize and explore rankings of items based on a set of heterogeneous attributes. This is a Jupyter Widget wrapper around the JavaScript library LineUp.js. Details about the LineUp visualization technique can be found at


  1. install Jupyter Widgets

    pip install ipywidgets
    jupyter nbextension enable --py widgetsnbextension
  2. install library

    pip install lineup_widget
    jupyter nbextension enable --py --sys-prefix lineup_widget
  3. OR directly via repository (requires node and npm to be installed):

    pip install -e git+
    jupyter nbextension enable --py --sys-prefix lineup_widget
  4. Jupyterlab

    jupyter labextension install @jupyter-widgets/jupyterlab-manager
    jupyter labextension install lineup_widget


Launch Binder

import lineup_widget
import pandas as pd
import numpy as np

df = pd.DataFrame(np.random.randint(0,100,size=(100, 4)), columns=list('ABCD'))

w = lineup_widget.LineUpWidget(df)
w.on_selection_changed(lambda selection: print(selection))

simple usage

from __future__ import print_function
from ipywidgets import interact, interactive, interact_manual

def selection_changed(selection):
    return df.iloc[selection]

interact(selection_changed, selection=lineup_widget.LineUpWidget(df));

interact example

Release Package

  1. JavaScript NPM

    cd js
    npm install
    npm publish
  2. Python PyPi

    pip install -U twine setuptools
    python clean sdist bdist_wheel
    twine upload dist/*
  3. Git

    git tag v<version>
    git push --follow-tags
  4. update versions edit the version in

    • js/package.json
    • js/version.ts
    • lineup_widget/


  • Samuel Gratzl (@sgratzl)

Project details

Download files

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

Files for lineup-widget, version 1.0.1
Filename, size File type Python version Upload date Hashes
Filename, size lineup_widget-1.0.1-py2.py3-none-any.whl (1.2 MB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size lineup_widget-1.0.1.tar.gz (575.6 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page