Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Variable do not persist in note book mode, but they persist when markdown is compiled
---
title: "R Notebook"
output:
html_document:
df_print: paged
---
```{r setup, include=FALSE}
knitr::opts_chunk$set(echo = TRUE)
library(reticulate)
```
```{python}
x = 1
```
```{python}
print(x)
```
```{r}
print(py$x)
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.