-
Notifications
You must be signed in to change notification settings - Fork 650
Description
It seems rCharts doesn't work well with Chinese
Background:
I've a csv cotains chinese characters,which is encoded in gb2313(system default) a sample of my csv is
date,title,name,id,message
"2014-10-07 8:42:37","元老",879231132,879231132,"加 "
"2014-10-07 8:43:50","元老",879231132,879231132,"这么多空格,不加引号。怎么行。 "
"2014-10-07 8:45:10","新人",451635342,451635342,"想问一下,如果有一些专业词汇不懂 找谁帮忙呀? "
"2014-10-07 8:45:30","大神",532594859,532594859,"发出来,一起研究 "
Problem:
I read them into R using read.csv,and it can be correctly print out in R Console.
But when I try to put the values into a label of hChart,its' shown as gibberish(characters with no meaning)
I'v tried Encoding(title)<- "UTF-8" and enc2utf8(),they don't work ,either.
How can I fix this??Any idea would be great helpful
Other Info:
R version 3.1.1 (2014-07-10)
Platform: i386-w64-mingw32/i386 (32-bit)
locale:
[1] LC_COLLATE=Chinese (Simplified)_People's Republic of China.936
[2] LC_CTYPE=Chinese (Simplified)_People's Republic of China.936
[3] LC_MONETARY=Chinese (Simplified)_People's Republic of China.936
[4] LC_NUMERIC=C
[5] LC_TIME=Chinese (Simplified)_People's Republic of China.936
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] RJSONIO_1.3-0 httr_0.5 rCharts_0.4.5
loaded via a namespace (and not attached):
[1] grid_3.1.1 lattice_0.20-29 plyr_1.8.1 Rcpp_0.11.3 stringr_0.6.2 tools_3.1.1
[7] whisker_0.3-2 yaml_2.1.13