Here is a minimal working example.
---
date : 2018-May-26
output:
pdf_document
title: "Testing Rmarkdown"
---
```{r,comment = NA}
Gender <- gl(2,1000,labels = c("Men","Women"))
SmokerM <- sample(c("Y","N"),1000,replace = T , prob = c(.3,.7))
SmokerW <- sample(c("Y","N"),1000,replace = T , prob = c(.5,.5))
Smoker <- c(SmokerM,SmokerW)
mydata <- data.frame(Gender,Smoker)
table(mydata$Gender,mydata$Smoker)
```
This is a text in the body of the document.What font is this ? What is
font for the output of table ? How can we change these 2 fonts ? What
other categories of items are there in an Rmarkdown which have different
fonts ?
My query is the following: What are the default fonts for an Rmarkdown document and how can I change them ?
While researching this I came across this page :
[Pandoc variables][1]http://pandoc.org/MANUAL.html#variables-for-latex
Is it correct that there are 4 fonts (mainfont/sansfont/monofont/mathfont) for describing 4 categories of output in Rmarkdown ? What are their default values and how can I change them ?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…