安装包 - 无法打开文件 - 权限被拒绝 [英] Installing package - cannot open file - permission denied

查看:65
本文介绍了安装包 - 无法打开文件 - 权限被拒绝的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 RStudio 中工作,正在尝试安装 dplyr 包.我已经毫无问题地安装了各种其他软件包,但遇到了这个问题.

I'm working in RStudio and am attempting to install the dplyr package. I have installed various other packages without problem but have hit a problem with this.

似乎安装有各个部分,其中一些工作正常,但是当我获得依赖项 BH"时会出现问题.这是错误:

It seems there are various parts to the install, some of these worked but the problem happens when I get 'the dependency BH'. This is the error:

>Installing package into ‘\\xxxxxxxx.local/Desktops/jagnew/My Documents/R/win-library/3.3’
    (as ‘lib’ is unspecified)
    also installing the dependency ‘BH’
    
>trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.3/BH_1.62.0-1.zip'
    Content type 'application/zip' length 16150075 bytes (15.4 MB)
    downloaded 15.4 MB
    
>trying URL 'https://cran.rstudio.com/bin/windows/contrib/3.3/dplyr_0.5.0.zip'
    Content type 'application/zip' length 2556205 bytes (2.4 MB)
    downloaded 2.4 MB
    
>Error in install.packages : cannot open file '\\xxxxxxx.local/Desktops/jagnew/My Documents/R/win-library/3.3/file142032c9327b/BH/include/boost/function/detail/gen_maybe_include.pl': Permission denied

我更改了目录/libpath,因为文件似乎没有下载到正确的文件夹.file142032c9327b 现在在正确的路径中,但是错误中指定的路径只正确到/boost,这里没有函数文件夹..?

I have changed the directory/libpath as it did not appear that the file was downloading to the correct folder. file142032c9327b is now in the correct path, but path specified in the error is only correct up to /boost, there is no function folder here..?

我不确定这个丢失的文件夹是否是问题所在,因为错误显示权限被拒绝",但这似乎很奇怪.

I'm not sure if this missing folder is the issue, as the error says 'Permission denied', but it seems odd.

推荐答案

我遇到了同样的问题.尝试执行以下操作并为我工作:

I had the same issue. Tried doing the following and worked for me:

  1. 以管理员身份运行 RStudio
  2. Packages 选项卡下,单击 Install 并将 Install to Library 选项更改为 C:/Program...../R/../library 并选择要安装的所需软件包.
  1. Run the RStudio as administrator
  2. Under the Packages tab, click Install and change Install to Library option to C:/Program...../R/../library and select the desired package to install.

希望它有效.

这篇关于安装包 - 无法打开文件 - 权限被拒绝的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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