Initialise and run the kernel
Description
Initialise and run the kernel
Usage
main(connection_file = "")main(connection_file = "")
Arguments
connection_file |
The path to the Jupyter connection file, written by the frontend |
| Title: | Native R Kernel for the 'Jupyter Notebook' |
|---|---|
| Description: | The R kernel for the 'Jupyter' environment executes R code which the front-end ('Jupyter Notebook' or other front-ends) submits to the kernel via the network. |
| Authors: | Thomas Kluyver [aut, cph], Philipp Angerer [aut, cph, cre] (ORCID: <https://orcid.org/0000-0002-0369-2888>), Jan Schulz [aut, cph], Karthik Ram [aut, cph] |
| Maintainer: | Philipp Angerer <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 1.3.2.9000 |
| Built: | 2026-05-10 08:29:13 UTC |
| Source: | https://github.com/irkernel/irkernel |
Get global CommManager instance
comm_manager()comm_manager()
CommManager instance if a kernel is running, else NULL
This can be called multiple times for different R interpreter, but you have to give a different name (and displayname to see a difference in the notebook UI). If the same name is give, it will overwrite older versions of the kernel spec with that name!
installspec( user = NULL, name = "ir", displayname = "R", rprofile = NULL, prefix = NULL, sys_prefix = NULL, verbose = getOption("verbose"), env = NULL )installspec( user = NULL, name = "ir", displayname = "R", rprofile = NULL, prefix = NULL, sys_prefix = NULL, verbose = getOption("verbose"), env = NULL )
user |
Install into user directory ( |
name |
The name of the kernel (default "ir") |
displayname |
The name which is displayed in the notebook (default: "R") |
rprofile |
(optional) Path to kernel-specific Rprofile (defaults to system-level settings) |
prefix |
(optional) Path to alternate directory to install kernelspec into (default: NULL) |
sys_prefix |
(optional) Install kernelspec using the |
verbose |
(optional) If |
env |
(optional) Named list of environment variables to set in the kernel (default: NULL) |
Exit code of the jupyter kernelspec install call.
Jupyter speaks a JSON+ZMQ protocol to a 'kernel' which is responsible for executing code. This package is a kernel for the R language.
jupyter_option_defaultsjupyter_option_defaults
An object of class list of length 7.
The following can be set/read via options(opt.name = ...) / getOption('opt.name')
jupyter.log_level1L (errors), 2L (warnings), or 3L (debug). 1L is the default.
jupyter.pager_classesClasses to use the pager for instead of displaying them inline. Default: help pages
jupyter.in_kernelTRUE if this code is executed in a running kernel. Set to pretend being/not being in a kernel
jupyter.rich_displayUse more than just text display
jupyter.display_mimetypesThe formats emitted when any return value is to be displayed (default: all mimetypes listed here)
jupyter.plot_mimetypesThe plot formats emitted to the frontend when a plot is displayed. (default: image/png and application/pdf)
jupyter.plot_scaleThe ratio (notebook PPI / repr.plot.res).
E.g.: With the defaults repr.plot.res=120 px/in (PPI) and jupyter.plot_scale=2,
a 1in1in image will be displayed as a 0.5in0.5in, 240 PPI image.
(default: 2, fit for retina displays)
A set of exported logging utilities that have the capability to be used in upstream projects.
Log level and log file can be set via R package options e.g. options(jupyter.log_level = 2L)
or from the environment variables JUPYTER_LOG_LEVEL and JUPYTER_LOGFILE.
log_debug(...) log_info(...) log_error(...)log_debug(...) log_info(...) log_error(...)
... |
message to log |
Initialise and run the kernel
main(connection_file = "")main(connection_file = "")
connection_file |
The path to the Jupyter connection file, written by the frontend |