1

我正在尝试生成一个带有“*”的表格作为单元格中的值:

---
title: "Untitled"
author: "James Durant"
date: "November 7, 2017"
output: pdf_document
---

```{r arthmatic, echo=FALSE}
library(knitr)
dfx <- data.frame(
  Operator = c("+", "-", "*", "/", "^", "**", "%%", "%/%"),
  Operation = c("addition", "subtraction", "multiplication", 
                "division", "exponentiation", "exponentiation",
                "modulus", "integer division")
  )
kable(dfx, escape = FALSE)
```

但是 * 和 ** 没有出现在表格中: 在此处输入图像描述

有任何想法吗?

4

1 回答 1

3

*\\text{*}或替换每个\\textasteriskcentered

于 2017-11-07T16:42:32.150 回答