轴标签不是用英文绘制的 [英] axis labels are not plotted in English

查看:75
本文介绍了轴标签不是用英文绘制的的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

R不会自动以英语(例如,月份为法语)绘制坐标轴标签. 我使用(如果该信息有用...):

R doesn't plot automatically the axis labels in English (for example Months are in French). I use (if the information is useful...):

  • windows(并且我已经在.../Programs/R/etc/Rconsole中将"language = zh"更改为R讲英语)
  • RStudio
  • ggplot2

我知道我不是唯一遇到此问题的人,但是我从未找到解决方案.

I know that I am not the only one with this issue but I never found a solution.

> sessionInfo()
R version 2.15.2 (2012-10-26)
Platform: x86_64-w64-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=French_France.1252  LC_CTYPE=French_France.1252 LC_MONETARY=French_France.1252 LC_NUMERIC=C LC_TIME=French_France.1252

推荐答案

要更改环境的语言,请使用以下命令:

To change language of the environment use the following command:

Sys.setenv("LANGUAGE"="En")

要将语言环境更改为英语:

To change locale to English:

Sys.setlocale("LC_ALL", "English")

语言环境的名称取决于系统上安装的语言(例如,您可以使用"en_GB.UTF-8"而不是英语").

The name of the locale depends on what is installed on your system (for example, you might use "en_GB.UTF-8" instead of "English").

这篇关于轴标签不是用英文绘制的的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆