Python figure

plot(1:10)
library("reticulate")
matplotlib <- import("matplotlib")
matplotlib$use("Agg", force = TRUE)

```{python py-plot} import matplotlib.pyplot as plt

x = range(1, 10) plt.plot(x, x)

```{python py-plot-w-fig.path, fig.path="to-be-ignored-and-generate-warning"}
import matplotlib.pyplot as plt

x = range(1, 10)
plt.plot(x, x)


Try the workflowr package in your browser

Any scripts or data that you put into this service are public.

workflowr documentation built on Aug. 23, 2023, 1:09 a.m.