问题描述
我对RStudio完全陌生,我正在研究RMarkdown文档.当我点击Knit PDF
时,我不断得到如下结果:
I am totally new to RStudio and I was working on an RMarkdown document. When I click on Knit PDF
, and I keep getting the result like this:
!软件包inputenc错误:Unicode字符μ(U + 3BC)
! Package inputenc Error: Unicode char μ (U+3BC)
(inputenc)未设置为与LaTeX一起使用.
(inputenc) not set up for use with LaTeX.
有关说明,请参见inputenc软件包文档.
See the inputenc package documentation for explanation.
输入H以立即获得帮助.
Type H for immediate help.
... l.142零假设:Ho:μ
... l.142 null hypothesis: Ho:μ
尝试使用--latex-engine = xelatex运行pandoc.
Try running pandoc with --latex-engine=xelatex.
pandoc:生成PDF时出错
pandoc: Error producing PDF
错误:pandoc文档转换失败,错误43
Error: pandoc document conversion failed with error 43
执行停止
我该如何解决这个问题并使事情正常进行?
How can I solve this and get things to work?
谢谢
推荐答案
此处的问题与编码有关.您试图在不应该包含ASCII字符的地方添加它们.
The issue here is related to encoding. You are trying to include ASCII characters where they should not be.
尤其是您输入了:
这需要更改为:
$H_0: \mu$
您将需要学习一些 LaTeX .
这篇关于无法在R Studio中编织PDF的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!