2016-11-20 9 views
0

私はRmardown次ニットしようとしています:Rマークダウン「マジックナンバー」エラー?

--- 
title: "Title" 
author: "Author" 
date: '20 nov 2016 г ' 
output: 
    pdf_document: 
    latex_engine: xelatex 
--- 
## Next inline code produced error: `r 98809` 

エラー:

processing file: 111.Rmd 
output file: 111.knit.md 

! Missing $ inserted. 
<inserted text> 
       $ 
l.91 ...e code produced error: 9.880910\^{}\{4\}}} 

pandoc.exe: Error producing PDF 
Ошибка: pandoc document conversion failed with error 43 

を、私は番号を編集し、ルックスに最後の「9」を削除した場合は、このr 9880は、すべての罰金になるだろう好き.. 。

これはバグですか?

私は新鮮なRでテストしています:

> sessionInfo() 
R version 3.3.2 (2016-10-31) 
Platform: x86_64-w64-mingw32/x64 (64-bit) 
Running under: Windows >= 8 x64 (build 9200) 

locale: 
[1] LC_COLLATE=Russian_Russia.1251 LC_CTYPE=Russian_Russia.1251 LC_MONETARY=Russian_Russia.1251 LC_NUMERIC=C     LC_TIME=Russian_Russia.1251  

attached base packages: 
[1] stats  graphics grDevices utils  datasets methods base  

loaded via a namespace (and not attached): 
[1] magrittr_1.5 assertthat_0.1 htmltools_0.3.5 tools_3.3.2  yaml_2.1.13  tibble_1.2  Rcpp_0.12.7  stringi_1.1.2 rmarkdown_1.1 stringr_1.1.0 digest_0.6.10 
[12] evaluate_0.10 
> 

答えて

0

は、ファイルの最後の行を変更してみてください。

## Next inline code produced error: `r format(98809)` 
+0

はい、それは働きます!しかし、なぜ? ) – atolk

+0

数字が大きいときは、10000より大きいとしましょう。数字が10の累乗でない場合は、scientific-formatを使用するかどうかを指定する必要があります。 –

関連する問題