- 已编辑
事情是酱紫的,我在使用 Rmd 文档时偶尔会遇到红点,有大神说红点是不可打印的字符,好巧不巧,我今天在将用户发来的邮件内容复制到 Rstudio Server 的 Rmd 文档时又遇到了这种红点。讲真,虽说可能只有机器能识别它,可我还是想知道怎么用人类的眼睛看到它。下面的两个文本中,其中一个里面就有红点。
```{r}
text1 <- "1. 立案责任"
print(text1)
text2 <- "1. 立案责任"
print(text2)
all.equal(text, text2)
```
[1] "1. 立案责任"
[1] "1. 立案责任"
[1] "1 string mismatch"
循例附上系统环境如下。
> sessionInfo()
R version 4.1.3 (2022-03-10)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: CentOS Linux 7 (Core)
Matrix products: default
BLAS: /R-4.1.3/lib64/R/lib/libRblas.so
LAPACK: /R-4.1.3/lib64/R/lib/libRlapack.so
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8 LC_MONETARY=en_US.UTF-8
[6] LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_US.UTF-8 LC_NAME=en_US.UTF-8 LC_ADDRESS=en_US.UTF-8 LC_TELEPHONE=en_US.UTF-8
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] DT_0.26 jiebaR_0.11 jiebaRD_0.1 echarts4r_0.4.4 data.table_1.14.2 RJDBC_0.2-8 rJava_0.9-13 DBI_1.1.0
loaded via a namespace (and not attached):
[1] Rcpp_1.0.8 pillar_1.6.4 compiler_4.1.3 later_1.3.0 tools_4.1.3 digest_0.6.29 jsonlite_1.7.3 evaluate_0.14 lifecycle_1.0.3
[10] tibble_3.1.6 pkgconfig_2.0.3 rlang_1.1.0 shiny_1.6.0 cli_3.6.0 rstudioapi_0.13 yaml_2.2.2 xfun_0.29 fastmap_1.1.0
[19] withr_2.5.0 stringr_1.5.0 dplyr_1.1.0 knitr_1.37 generics_0.1.0 vctrs_0.6.0 htmlwidgets_1.5.3 tidyselect_1.2.0 glue_1.6.1
[28] R6_2.5.1 fansi_1.0.2 rmarkdown_2.10 magrittr_2.0.1 promises_1.2.0.1 ellipsis_0.3.2 htmltools_0.5.2 mime_0.12 xtable_1.8-4
[37] httpuv_1.6.5 utf8_1.2.2 stringi_1.7.3 crayon_1.4.2