Comments (3)
Hello @jmcphers, it has been a while since we discussed this. In the meantime I have made significant progress on my project, and I officially announced it one month ago. As you can see, the project was very well received by the community of Jupyter users, as people were missing the text notebook functionality.
The project now includes a few other notebooks formats, and we can now represent notebooks as Python or R (or Julia, etc) scripts. Obviously this is somehow related to knit::spin
's format.
The point I would like to discuss now with you is the following: while R Markdown can accept any language, (and is indeed a great format for Python code as well), the fact that the code options have to be coded in R make it
- difficult to adopt by non R users
- and difficult to parse in other languages than R (think of Python or even Javascript, which is used by many editors, like Hydrogen or VScode).
Among the formats for notebooks as scripts (documented here), we now have two formats that are almost language agnostic. For simplicity the cell metadata are represented using JSON in these formats.
Now my question: do you think it would be feasible to design a flavor of the R Markdown format with code options represented in a non R format (say, JSON)?
from jupytext.
Defining a shared notebook specification which serves the needs of users on both platforms while meeting the constraints laid out here is not impossible, but it's an ambitious undertaking!
Re: your last two bullet points, R Markdown notebooks can do this, too. If you save a notebook, a .nb.html
file is generated. It's very Jupyter-like, a fully rendered HTML copy of the notebook, with outputs--and also embeds the original Rmd file. Using the .nb.html
file to read outputs can give you the best of both worlds: version control on plain text, and a self-contained file with embedded outputs you can share or publish.
More on the R Notebook HTML format with embedded outputs here:
https://rmarkdown.rstudio.com/r_notebook_format.html
from jupytext.
Well, sure. A few more thoughts
- R Markdown is by itself a great specification! What is missing is a standard way to translate Rmd chunk options into Jupyter cell metadata, which don't seem to be widely used.
- Translating
.Rmd
to.ipynb
works well withnbrmd
. There are also a few alternative around: see https://github.com/aaren/notedown and https://github.com/grst/ipymd . - Getting a notebook to be fully executable with both Jupyter and RStudio works only to a certain extend. I expect it to work well if
- notebook is 100% R
- or 100% python, with no cell magics. Matplotlib plots are supported, but javascript plots are not yet working.
from jupytext.
Related Issues (20)
- reinstate `:` in valid metadata keys ? HOT 4
- Extension fails to load in ServerApp HOT 1
- Use callback to frontend extension Settings change to add/remove entries to launcher and main menu
- Unable to unpair ipynb in jupyter notebook HOT 7
- Add Galata UI tests for notebook
- Replace toml package with tomli HOT 3
- Panel widget event triggers are not working in py:percent notebooks HOT 2
- Write temporary notebooks to a `TemporaryDirectory` rather than `NamedTemporaryFile`
- feature request: automatic creation of missing notebooks for use after git clone
- Using jupytext in a nested project can result in re-import of the current module HOT 2
- Enable the discussions section for the repository HOT 2
- The Jupytext pre-commit hook fails to install when node is not available HOT 2
- Ability to specify jupytext as the viewer via URL HOT 5
- --sync: avoid updating timestamp of *.py if nothing changes HOT 11
- jupytext-config set-default-viewer failing with a miniconda install on Windows 10 HOT 2
- Convert Jupyter Notebooks with R code cells to ```r code cells
- Automatic code cell detection HOT 3
- Jupytext corrupts original notebook with base64 of pair HOT 1
- Allow to provide the output argument when providing multiple files with --set-formats HOT 1
- indented magic commands block all magic commands HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jupytext.