Jupyter notebook

Draft

Jupyter notebook, python. A “web-based computational environment”

Project homepage: https://jupyter.org/

Wikipedia

Besides the python kernel, Jupyter kernels include

Cytoscape

SageMATH

and, of course R, which along with python and Julia, is one of the core programming languages available in Jupyter. We present how to install the IRkernel on this page.

In the cloud

Access to Jupyter notebook was discussed for running R in the cloud.

Local installation

# install latest python 3.12.4
# https://www.python.org/

# https://www.python.org/downloads/windows/
# macOS universal installer
# https://www.python.org/downloads/macos/

# default python on macOS
# see how to bash alias at https://stackoverflow.com/questions/18425379/how-to-set-pythons-default-version-to-3-x-on-os-x

# Open terminal
python3 –version
python3 -m pip –version
# pip3 install jupyterlab

pip install jupyterlab
jupyter lab
browser opens http://localhost:8888/lab

Install IRkernel from CRAN

# Run R in terminal as administrator
sudo R
# At R prompt enter
install.packages(“IRkernel”)
# Making the kernel available to Jupyter
IRkernel::installspec(user = FALSE)

Run R as Jupyter Notebook

In the terminal, type at the bash shell line

jupyter lab

start jupyter lab in terminal

Figure cc. Screenshot of terminal with command

Set working drive, then load kernel. Select the R kernel and create a new Notebook, Figure cc  (i.e., don’t select a Console, Fig. cc).

jupyter start page, select kernel

Figure cc. Screenshot of Jupyter Lab. Select R icon under Notebook to set IRkernel.

Ready to go, Figure cc.

R Jupyter Notebook

Figure cc. Screenshot of Jupyter Notebook running the IRkernel.

R running as Console in Jupyter

Figure cc. Screenshot of Jupyter Console running the IRkernel.

It’s easy to switch kernels. Let’s say you started Jupyter Lab and notice that Python is running (Fig. cc). Click on the kernel name — see green arrow in Figure cc — to bring up a popup menu, Fig cc.

identify kernel

Figure cc. Screenshot of Notebook with Python set as kernel.

switch kernel popup menu

Figure cc. Screenshot of select kernel popup menu

Click on the drop arrow and select R kernel (figure cc), then click on blue Select button (see Figure cc).

switch kernel, select R

Figure cc. Screenshot of installed kernels

Once

kernel set to R

Free apps for Bioinformatics

Mike’s recommended free and or open source apps for bioinformatics on macOS or Windows 11 pcs.

Note: Chrome OS users. If your device is Intel-based, then it is possible to install many of the apps (or equivalents) listed via activating LINUX on your device. This route is only advisable if you are willing and able to do some pretty serious installation work.

Statistics

R Core Team (2024). R: A language and environment for statistical computing. R Foundation for Statistical Computing, Vienna, Austria. URL https://www.R-project.org/.

Python programming language and libraries: panda, Numby, Scipy, Matplotlib, Biopython, PySB, and others

Mathematics software

GNU Octave, free and open source, uses similar programming syntax to MATLAB, https://octave.org/

SageMATH, python based, free and open source alternative to MATLAB and Wolfram Mathematicahttps://www.sagemath.org/

Image, Drawing, Concept & Mind maps, Flow charts

Newt Editor, a free, web based, open source viewer and editor for biology pathways, https://newteditor.org/index.html

Draw.io, used to create work flows, mind maps, https://app.diagrams.net/

FreeCAD, open source “parametric 3D modeler”, https://www.freecad.org/

GIMP, GNU Image Manipulation Program, at https://www.gimp.org/

ImageJ2, JAVA-based, https://imagej.net/software/imagej2/

Krita, free and open source painting program, https://krita.org/en/

Preview, macos only

Video editor

Shortcut, at https://shotcut.org/

Handbrake, at https://handbrake.fr/

Screen recording, Video streaming

OBS Studio, at https://obsproject.com/

QuickTimePlayer, macos only

Office suite (compatible with Microsoft Word)

LibreOffice, at https://www.libreoffice.org/

Reference manager

Zotero, https://www.zotero.org/

 

Digital Notebook

Jupyter Lab and Notebooks, python based, web-based computational notebooks. In addition to python, Jupyter supports Julia and R Programming languages as well as Cytoscape, GNU Octave, SageMATH and other software. https://docs.jupyter.org/en/latest/index.html

OneNote, at https://www.onenote.com/

Bioinformatics tools

Bioconductor, at https://www.bioconductor.org/

Unipro UGENE, at http://ugene.net/

Cytoscape, at https://cytoscape.org/

MEGA, at https://www.megasoftware.net/

Coding IDE and code editor

Jupyter Lab

Visual Studio with Python application, Community edition, https://visualstudio.microsoft.com/vs/features/python/

Posit team (2024). RStudio: Integrated Development Environment for R. Posit Software, PBC, Boston, MA URL http://www.posit.co/.