starticles: A Generic, Publisher-Independent Template for Writing...

starticlesR Documentation

A Generic, Publisher-Independent Template for Writing Scientific Documents in 'rmarkdown'

Description

A Generic, Publisher-Independent Template for Writing Scientific Documents in 'rmarkdown'

Details

This package provides a 'rmarkdown' template for authoring scientific documents that is publisher independent. Though the template can be used by itself for many types of scientific documents and likely for submitting publications to many journals, it is primarily intended as a starter format for writing a scientific publication before one has chosen a specific target journal. Once an article has been written, the format can be quickly adapted for use with the rticles package. See the package vignette for more details.

Package: starticles
Type: Package
Version: 0.1
Date: 2022-06-07
License: GPL (>= 3)

Author(s)

David M. Kaplan dmkaplan2000@gmail.com

See Also

browseVignettes("starticles"), rmarkdown, rticles

Examples

# Use a temporary directory ----------------------------
owd = getwd()
td = tempfile()
dir.create(td,recursive=TRUE)
setwd(td)
print(td) # To see where files will be

# Create the draft template ----------------------------
rmarkdown::draft("MYARTICLENAME.Rmd","generic_article","starticles",edit=FALSE)

# Render PDF document ----------------------------------
# Fails for me when run using RStudio "Run examples" link in help,
# but not when sourced from command line.

# Requires recent version of pandoc (provided by RStudio)
if (rmarkdown::pandoc_available(version="2.17"))
  rmarkdown::render("MYARTICLENAME/MYARTICLENAME.Rmd",
                    envir=new.env(parent = globalenv()))

# Return to orignal workind directory ------------------
setwd(owd)

starticles documentation built on June 9, 2022, 9:06 a.m.