镜像下载、域名解析、时间同步请点击 阿里云开源镜像站

方法一:

打开RStudio,输入options()$repos查看默认镜像源情况

  1. options()$repos

file

打开tools工具栏,找到Global Options

file

找到Packages,点击右边的add

file

出现添加镜像源的对话框,name处填入aliyun,url填入:https://mirrors.aliyun.com/CRAN/, 点击ok保存

file

在命令栏输入options()$repos查看镜像源情况

file

方法二:

找到C盘,program files文件下,R/R-4.0.3/etc中的Rprofile文件

file

file

原来的:

  1. # Things you might want to change
  2. # options(papersize="a4")
  3. # options(editor="notepad")
  4. # options(pager="internal")
  5. # set the default help type
  6. # options(help_type="text")
  7. options(help_type="html")
  8. # set a site library
  9. # .Library.site <- file.path(chartr("\\", "/", R.home()), "site-library")
  10. # set a CRAN mirror
  11. # local({r <- getOption("repos")
  12. # r["CRAN"] <- "http://my.local.cran"
  13. # options(repos=r)})
  14. # Give a fortune cookie, but only to interactive sessions
  15. # (This would need the fortunes package to be installed.)
  16. # if (interactive())
  17. # fortunes::fortune()

修改后:

  1. # set a CRAN mirror
  2. local({r <- getOption("repos")
  3. r["CRAN"] <- "https://mirrors.aliyun.com/CRAN/"
  4. options(repos=r)})

本文转自:https://blog.csdn.net/sxqcj007/article/details/123181776

更多相关文章

  1. android使用全局变量的两种方法
  2. TabHost 置于底部 顶部的方法
  3. Android中打电话的数据流程
  4. Android输入管理_InputManager服务启动
  5. 修改android项目sdk版本的方法
  6. Android,TextView的所有属性和方法
  7. Android(安卓)Studio Error 安装后Gradle:resolve dependencies:
  8. 【Android(安卓)开发教程】屏幕方向的改变
  9. Android(安卓)ColorStateList使用方法

随机推荐

  1. Frida入门学习笔记-hook native中的函数(
  2. 【摘录】Linux下Android(安卓)ADB驱动安
  3. Android(安卓)控件之TextView常见使用问
  4. Android界面刷新方法
  5. android4.0.3 修改启动动画和开机声音
  6. google编程
  7. Android桌面组件App Widget开发三步走
  8. android中版本webView中js不执行问题
  9. 异步任务加载网络数据——AsyncTask使用
  10. android studio中常用快捷键