Cool trick I recently learned to interpret R within Latex. This means you can print R objects in a sentence and have it not look like markdown. This can be a cool time saving trick if you only need to do some rudimentary calculations for your document (e.g. summary statistic calculation).
<<echo=FALSE>>=
dat <- read.csv("./data/publication_data.csv")
for(i in 14:55){
dat[,i] <- gsub("\n","",dat[,i])
}
uniq_studies <- length(unique(dat$Citation))
uniq_hosts <- length(unique(dat$Host_taxon))
@
NOTE: the code I use here is copied from something I am working on and is not a reproducible example. But you get the idea.Next, you can call objects within your text using $\Sexpr{yourcode}$. For instance: "Our survey immediately highlighted the dramatic breadth of the endophyte biodiversity literature, as we surveyed $\Sexpr{uniq_studies}$ studies."
Highlight important information in a panel like this one. To edit this panel's color or style, select one of the options in the menu below. |
The content by label feature displays related articles automatically, based on labels you choose. To edit options for this feature, select the placeholder below and tap the pencil icon.
|