ProductPromotion
Logo

Ruby

made by https://0x3d.site

GitHub - SciRuby/iruby: Official gem repository: Ruby kernel for Jupyter/IPython Notebook
Official gem repository: Ruby kernel for Jupyter/IPython Notebook - SciRuby/iruby
Visit Site

GitHub - SciRuby/iruby: Official gem repository: Ruby kernel for Jupyter/IPython Notebook

GitHub - SciRuby/iruby: Official gem repository: Ruby kernel for Jupyter/IPython Notebook

IRuby

Gem Version Build Status Binder

IRuby is a Ruby kernel for Jupyter project.

Try IRuby

You can try IRuby with a sample notebook on Binder (the same link as the banner placed above):

https://mybinder.org/v2/gh/RubyData/binder/master?filepath=ruby-data.ipynb

The following URL launches JupyterLab directly on Binder.

https://mybinder.org/v2/gh/RubyData/binder/master?filepath=../lab

Installation

Requirements

The following requirements are automatically installed.

The following dependencies are optional.

  • Pry, if you want to use Pry instead of IRB for the code execution backend

Installing Jupyter Notebook and/or JupyterLab

See the official document to know how to install Jupyter Notebook and/or JupyterLab.

Ubuntu

Ubuntu 17+

sudo apt install libtool libffi-dev ruby ruby-dev make

gem install --user-install iruby
iruby register --force

Ubuntu 16

The latest IRuby requires Ruby >= 2.4 while Ubuntu's official Ruby package is version 2.3. So you need to install Ruby >= 2.4 by yourself before preparing IRuby. We recommend to use rbenv.

sudo apt install libtool libffi-dev ruby ruby-dev make
gem install --user-install iruby
iruby register --force

Fedora

Fedora 36

sudo dnf install ruby ruby-dev make zeromq-devel

gem install --user-install iruby
iruby register --force

Windows

DevKit is necessary for building RubyGems with native C-based extensions.

gem install iruby
iruby register --force

macOS

Install ruby with rbenv or rvm. Install Jupyter.

Homebrew

gem install iruby
iruby register --force

MacPorts

If you are using macports, run the following commands.

port install libtool autoconf automake autogen
gem install iruby
iruby register --force

Docker

Try RubyData Docker Stacks. Running jupyter notebook:

docker run --rm -it -p 8888:8888 rubydata/datascience-notebook

Installation for JRuby

You can use Java classes in your IRuby notebook.

  • JRuby version >= 9.0.4.0
  • iruby gem

After installation, make sure that your env is set up to use jruby.

env ruby -v

If you use RVM, it is enough to switch the current version to jruby.

If you have already used IRuby with a different version, you need to generate a new kernel:

iruby register --force

Install the development version of IRuby

Be careful to use the development version because it is usually unstable.

If you want to install the development version of IRuby from the source code, try specific_install.

gem specific_install https://github.com/SciRuby/iruby

Note for using with CZTop and CZMQ

CZTop adapter has been deprecated since IRuby version 0.7.4. It will be removed after several versions.

If you want to use IRuby with CZTop, you need to install it and CZMQ.

If both ffi-rzmq and cztop are installed, ffi-rzmq is used. If you prefer cztop, set the following environment variable.

export IRUBY_SESSION_ADAPTER="cztop"

Backends

There are two backends: PlainBackend and PryBackend.

  • PlainBackend is the default backend. It uses IRB.
  • PryBackend uses Pry.

You can switch the backend to PryBackend by running the code below.

IRuby::Kernel.instance.switch_backend!(:pry)

Notebooks

Take a look at the example notebook and the collection of notebooks which includes a Dockerfile to create a containerized installation of iruby and other scientific gems. You can find the prebuild image at dockerhub.

Contributing

Contributions to IRuby are very welcome.

To former contributors

In February 2021, IRuby became the canonical repository and is no longer a fork from minrk/iruby. Please fork from this repository again before making pull requests.

License

Copyright (c) IRuby contributors and the Ruby Science Foundation.

Licensed under the MIT license.

More Resources
to explore the angular.

mail [email protected] to add your project or resources here 🔥.

Related Articles
to learn about angular.

FAQ's
to learn more about Angular JS.

mail [email protected] to add more queries here 🔍.

More Sites
to check out once you're finished browsing here.

0x3d
https://www.0x3d.site/
0x3d is designed for aggregating information.
NodeJS
https://nodejs.0x3d.site/
NodeJS Online Directory
Cross Platform
https://cross-platform.0x3d.site/
Cross Platform Online Directory
Open Source
https://open-source.0x3d.site/
Open Source Online Directory
Analytics
https://analytics.0x3d.site/
Analytics Online Directory
JavaScript
https://javascript.0x3d.site/
JavaScript Online Directory
GoLang
https://golang.0x3d.site/
GoLang Online Directory
Python
https://python.0x3d.site/
Python Online Directory
Swift
https://swift.0x3d.site/
Swift Online Directory
Rust
https://rust.0x3d.site/
Rust Online Directory
Scala
https://scala.0x3d.site/
Scala Online Directory
Ruby
https://ruby.0x3d.site/
Ruby Online Directory
Clojure
https://clojure.0x3d.site/
Clojure Online Directory
Elixir
https://elixir.0x3d.site/
Elixir Online Directory
Elm
https://elm.0x3d.site/
Elm Online Directory
Lua
https://lua.0x3d.site/
Lua Online Directory
C Programming
https://c-programming.0x3d.site/
C Programming Online Directory
C++ Programming
https://cpp-programming.0x3d.site/
C++ Programming Online Directory
R Programming
https://r-programming.0x3d.site/
R Programming Online Directory
Perl
https://perl.0x3d.site/
Perl Online Directory
Java
https://java.0x3d.site/
Java Online Directory
Kotlin
https://kotlin.0x3d.site/
Kotlin Online Directory
PHP
https://php.0x3d.site/
PHP Online Directory
React JS
https://react.0x3d.site/
React JS Online Directory
Angular
https://angular.0x3d.site/
Angular JS Online Directory