working_with_python.md (412B)
1 # working_with_python 2 :rmarkdown: 3 4 # Enabling Python in RMD 5 Install the reticulate package. 6 Enable it as below. 7 It's the bee's knees. 8 9 # Conda environments 10 Call an R command `use_condaenv("env_name")` like so: 11 12 ```{r, echo=FALSE} 13 library(reticulate) 14 use_condaenv("lgb_shap") 15 ``` 16 17 # Matplotlib plots 18 They work. Make sure to call `plt.tight_layout()` so the formatting is pretty. 19 20 21 Sun 17 Nov 2019 10:23:05 AM CST