2

Is it possible to export documents that contain Korean letters using knitr? I've tried it but it didn't work.

All Korean font changing like this, but all Korean letters work in R console.

enter image description here

halfer
  • 19,824
  • 17
  • 99
  • 186
user46543
  • 1,033
  • 4
  • 13
  • 23
  • Don't you think it might be useful to show what you have tried? Anyway, this might be related to [this](http://stackoverflow.com/questions/22137529/knitr-lyx-mac-korean#comment33591097_22137529). –  Jul 02 '14 at 07:28
  • @Pascal I've add figure in my question, so it means this is bug? – user46543 Jul 02 '14 at 07:34
  • This is not a bug, it's an encoding issue. Add a line to your knitr document that will display which encoding it's using (probably `native.enc`?). – Roman Luštrik Jul 02 '14 at 07:40

1 Answers1

0

A quick and lazy solution is to use RStudio, which should handle the character encoding automatically. If you use other editors, or just call knitr::knit() manually, you should provide a proper value to the encoding argument. BTW, please post library(knitr);sessionInfo().

Yihui Xie
  • 28,913
  • 23
  • 193
  • 419