Wasm comes to R

Posit, formerly know as RStudio, has debuted an early version of an R package, aimed at developers, that brings WebAssembly (Wasm) to R.

Two developers collaborate on a project as they review code on a display in their workspace.
Posit (formerly RStudio) today released an early version of an R package that brings WebAssembly (Wasm) to R.
 
Aimed at developers, the WebR package (available at https://docs.r-wasm.org/webr/latest/) "is a version of the open-source R interpreter compiled for WebAssembly, along with a supporting [JavaScript] TypeScript library," Posit's George Stagg wrote in a blog post this morning.
 
"Absolute game changer of an #RStats package," Bruno Rodrigues, author of the chronicler R package, said in a post on Mastodon.
 
The project includes a webR kernel for the JupyterLite Wasm project for Jupyter notebooks. That means users of JupyterLite can now run R code as well as Python in their notebooks. You can see that implemented at: https://jupyter.r-wasm.org/lab/index.html
 
The package includes a demo Web-based interactive R console. A version of that console is currently online at: https://webr.r-wasm.org/latest/.
 
Creators of WebR envision package developers using the Web console in online documentation, so those interested in a package could try it out without having to install it locally or run installation in the cloud.
 
In addition, it could have a number of uses in education and training. And, Stagg wrote, it offers the potential for a version of Shiny Web framework for R that wouldn't require an R server. The new Shiny for Python already doesn't require a server.
 

Copyright © 2023 IDG Communications, Inc.