首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >尝试编织R标记时出错:!软件包输入错误:未设置用于LaTeX的Unicode character锛(U+FF0C)(输入)

尝试编织R标记时出错:!软件包输入错误:未设置用于LaTeX的Unicode character锛(U+FF0C)(输入)
EN

Stack Overflow用户
提问于 2021-01-27 13:30:27
回答 1查看 529关注 0票数 0

这个错误显然与Latex有关,我已经尽了最大的努力谷歌并解决了它,但我得到的只是更多的错误。

初始错误:

代码语言:javascript
运行
复制
! Package inputenc Error: Unicode character 锛?(U+FF0C)
(inputenc)                not set up for use with LaTeX.

Try other LaTeX engines instead (e.g., xelatex) if you are using pdflatex. See https://bookdown.org/yihui/rmarkdown-cookbook/latex-unicode.html
错误: LaTeX failed to compile Jan-26-in-class-code.tex. See https://yihui.org/tinytex/r/#debugging for debugging tips. See Jan-26-in-class-code.log for more info.
此外: Warning message:
In grepl("==> Fatal error occurred", x[i], fixed = TRUE) :
  输入的字符串1不适用于此语言环境
停止执行

所以我尝试了xelatex。然后我得到了

代码语言:javascript
运行
复制
! LaTeX Error: File `unicode-math.sty' not found.

! Emergency stop.
<read *> 

! Unfortunately, the package unicode-math could not be installed.

! Please check the log file:

! C:\Users\86188\AppData\Local\MiKTeX\2.9\miktex\log\xelatex.log

错误: LaTeX failed to compile Jan-26-in-class-code.tex. See https://yihui.org/tinytex/r/#debugging for debugging tips. See Jan-26-in-class-code.log for more info.
停止执行

我猜问题是我的计算机上没有安装"unicode-math“,所以我尝试了install.packages("unicode-math"),然后我得到了

代码语言:javascript
运行
复制
Warning in install.packages :
  package ‘unicode-math’ is not available for this version of R

我真诚地感谢您的任何指示或建议。谢谢!

EN

回答 1

Stack Overflow用户

发布于 2021-01-27 16:57:39

unicode-math是一个LaTeX包,而不是R包,因此需要使用LateX包管理器进行安装;如果使用TeX实时分发版,则使用tlmgr,或者将MiKTeX控制台与MiKTeX (通常是TeX主分发版)一起使用。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/65913390

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档