Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我并不完全清楚您要做什么,但是取回原始字符的问题是 R 无法从原始字节自动确定编码。我假设你在 Windows 上。如果你这样做
val <- rawToChar(charToRaw("\uFF06")) val # [1] "&" Encoding(val) # [1] "unknown" Encoding(val) <- "UTF-8" val # [1] "&"
只要确保正确设置编码。