Skip to main content

GenePattern Notebook extension for JupyterLab

Project description

Version Build Documentation Status Docker Pulls Join the chat at https://gitter.im/genepattern

GenePattern Notebook for JupyterLab

The GenePattern Notebook environment gives GenePattern users the ability to interleave text, graphics, and code with their GenePattern analyses to create "notebooks" that can be edited, shared, and published. GenePattern Notebooks are built on the Jupyter environment and extend it so that users can take advantage of its ease of use and ability to encapsulate an entire scientific research narrative, without the need to write code.

Prerequisites

  • JupyterLab >= 2.0.0
  • ipywidgets >= 7.0.0

Docker

A Docker image with nbtools and the full JupyterLab stack is available through DockerHub.

docker pull genepattern/lab
docker run --rm -p 8888:8888 genepattern/lab

Installation

Full installation instructions for casual use are detailed on the GenePattern Notebook website. Users should also consider the GenePattern Notebook Repository, which provides an install-free cloud deployment of the GenePattern Notebook environment.

Development Install

The installation instructions below are intended for developers who want to install the project from PIP or GitHub for the purposes of software development.

Install Python

In order to get the GenePattern Notebook working you will first need to install a compatible version of Python. This means you will need Python 3.4+. We recommend using the Anaconda Python distribution. This is a scientific version of Python that ships with many of the most popular Python packages for science, math and data analysis (ex: NumPy, SciPy, Pandas, Matplotlib, IPython, etc.).

Note for Mac Users: Mac comes with Python, but you will need to install a newer version, as OSX ships with Python 2.

Install GenePattern Notebook from GitHub

Copy the contents of genepattern-notebook/extension to your development computer and ensure that the resulting directory if on your Python path. To test this, open Python and try to import genepattern. If this is successful, you have a copy of the extension available.

If you don't already have Jupyter installed, you can install it from PIP by running:

pip install jupyter

From here go to the "Load the GenePattern extension" step below.

Install GenePattern Notebook from PIP or Conda

The easiest way to install GenePattern Notebook is through either PIP or conda. It can be installed by executing one of the following commands:

pip install genepattern-notebook

or

conda install -c genepattern genepattern-notebook

Load the nbtools extension

# Install ipywidgets, if you haven't already
jupyter nbextension enable --py widgetsnbextension
jupyter labextension install @jupyter-widgets/jupyterlab-manager

# Clone the nbtools repository
git clone https://github.com/genepattern/nbtools-lab-prototype.git
cd nbtools-lab-prototype

# Install the nbtools JupyterLab prototype
pip install .
jupyter labextension install .
jupyter nbextension install --py nbtools --sys-prefix
jupyter nbextension enable --py nbtools --sys-prefix

Launch Jupyter

Finally, you may launch JupyterLab by issuing the following command at the terminal:

jupyter lab

This will start up the notebook kernel and launch your web browser pointing to the Notebook.

Related Repositories

The following GitHub repositories contain code or other data related to the GenePattern Notebook environment.

  • genepattern-python: The GenePattern Library allows for programmatic access to GenePattern from Python, and is used by GenePattern Notebook behind the scenes.
  • nbtool-manager: The Notebook Tool Manager is a tool-agnostic interface and registry for searching, browsing and launching available notebook tools in a Jupyter environment.
  • jupyter-wysiwyg: A WYSIWYG editor for markdown cells.
  • example-notebooks: A repository of example notebooks that demonstrate functionality or analysis techniques in the GenePattern Notebook environment.
  • notebook-docker: A collection of Dockerfiles which are used to build containers encapsulating the GenePattern Notebook environment.
  • notebook-repository: Scripts, services and other infrastructure used in the operation of the GenePattern Notebook Repository.

Known Issues

The current version of the code only works with GenePattern 3.9.3 and up!

Users using the GenePattern Notebook with an older version of GenePattern (3.9.3 or 3.9.4) may need to log into the GenePattern UI before making use of the notebook. The server status message and child jobs will also be unavailable. If you are using one of these older versions, we recommend that you upgrade to the latest version of GenePattern.

Code of Conduct

We are dedicated to providing a harassment-free experience for all members of the GenePattern community, regardless of gender, gender identity and expression, sexual orientation, disability, physical appearance, body size, age, race, or religion. We do not tolerate harassment of participants in any form. This code of conduct applies to all GenePattern spaces, including the Google Group, our Git repositories, and our social media accounts, both online and off. Anyone who violates this code of conduct may be sanctioned or expelled from these spaces at the discretion of the GenePattern team.

For more details, see our Code of Conduct.

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

genepattern-notebook-21.8b1.tar.gz (18.4 kB view details)

Uploaded Source

Built Distribution

genepattern_notebook-21.8b1-py3-none-any.whl (655.0 kB view details)

Uploaded Python 3

File details

Details for the file genepattern-notebook-21.8b1.tar.gz.

File metadata

  • Download URL: genepattern-notebook-21.8b1.tar.gz
  • Upload date:
  • Size: 18.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.26.0 setuptools/49.6.0.post20210108 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.5

File hashes

Hashes for genepattern-notebook-21.8b1.tar.gz
Algorithm Hash digest
SHA256 51198615c11693c6e06c2a63180c4151641106109340fd9530d5718121962c1d
MD5 0078a55b630e216ddb45df6b40f10991
BLAKE2b-256 608156a3a209650674ee7c3f85d28cbf44112c93cacd4946184dbd79250ad6f7

See more details on using hashes here.

File details

Details for the file genepattern_notebook-21.8b1-py3-none-any.whl.

File metadata

  • Download URL: genepattern_notebook-21.8b1-py3-none-any.whl
  • Upload date:
  • Size: 655.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.26.0 setuptools/49.6.0.post20210108 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.8.5

File hashes

Hashes for genepattern_notebook-21.8b1-py3-none-any.whl
Algorithm Hash digest
SHA256 a0b27f6f0d7626689bc40f469c79b7a4d65b6738d4499a20aab7204721d14987
MD5 6916a4618aca9bf5d45badefee438c2f
BLAKE2b-256 64140b36511c6c28da7991acef604b5f2a532b91182f3a649f72856382c5b843

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