Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

dir() and list.files() fail to list file names with East Asian characters after R update

Tags:

r

dir() and list.files() list all files names in R version 4.2.3, but not in R version 4.3.2.

R version 4.2.3

version 4.2.3

R version 4.3.2

version 4.3.2

like image 819
user3394975 Avatar asked Sep 13 '25 03:09

user3394975


1 Answers

What you observe is related to a change in the Windows implementation of list.files between R versions 4.2.3 and 4.3.0. The issue was reported on one of the mailing lists in August (here). That discussion led to a patch in R-devel (revision 84960), but it is not clear whether the patch solved the issue, because the person who reported the issue did not reply.

It would be great if you could download and install R-devel (here) and verify whether list.files behaves correctly there. If you do so, then please report your findings here or (ideally) on the mailing list.

like image 189
Mikael Jagan Avatar answered Sep 14 '25 16:09

Mikael Jagan