New R notebook default template "notebook_osx.rmd"

I created

~/.config/rstudio/templates

and saved a copy of the default notebook.Rmd there with a change to the title to show that it had come from that location, rather than the default path

/Applications/RStudio.app/Contents/Resources/app/resources/templates

which was created by the installation of RStudio.app (I didn't do that manually).

Creating a new notebook uses the template from ~/.config/rstudio/templates. Opening an existing notebook shows whatever template it was created with.

Any template applied by the new notebook file option has to be named notebook.rmd; notebook_osx.Rmd won't work.

1 Like