Question / Answer pdf Latex

时间:2019-07-04 10:34:29

标签: r r-markdown pdflatex

我有此代码:

Question 4.02 - [Question text]

```{r echo=FALSE, include = TRUE, warning=FALSE, message=FALSE, results='asis'}
n = match(c("4.02_1"),row.names(questionnaire.matrix))
for (i in 0:3){
  if ((question$s4[n+i]) != "") {
    cat("\t", "\t","-", (question$s4[n+i]),"\n")
    cat("\n")
  }
}
```

现在我有这个输出:

Question 4.02 - [Question text]

              - Answer

但是我的pdf需要这种输出格式:

Question 4.02 - Answer......

我尝试通过这种方式进行修改:

Question 4.02 - ```{r echo=FALSE, include = TRUE, warning=FALSE, message=FALSE, results='asis'}
..code...
                ```

但不起作用。

我该怎么办?

0 个答案:

没有答案