Installing R Packages Error in readRDS(file) : error reading from connection

后端 未结 9 1451
鱼传尺愫
鱼传尺愫 2021-01-03 19:48

Whenever I try to install any package in R on Ubuntu 14.04, I\'m getting the following error:

Error in readRDS(file) : error reading from connection
<         


        
相关标签:
9条回答
  • 2021-01-03 20:22

    I was facing the same error when i installed most recent version of R. many a times most recent version is not stable( for me, it was 3.4.2 on 08/11/2017). I uninstalled it and installed 3.4.1( earlier stable version), now there is no issue.

    0 讨论(0)
  • 2021-01-03 20:29

    1- Install the latest version of R form the CRAN and try to install a package.

    2- If it is possible check it with another user account.

    3- Try to install the R package locally.

    4- If there is an RDS file created by the old version of R you may have another sort of problem, this is the warning from R help:

    Warning

    These functions have provided a stable interface since R 2.4.0 (when the storage of serialized objects was changed from character to raw vectors). However, the serialization format may change in future versions of R, so this interface should not be used for long-term storage of R objects.

    On 32-bit platforms a raw vector is limited to 2^31 - 1 bytes, but R objects can exceed this and their serializations will normally be larger than the objects.

    Ref: help(serialize)

    0 讨论(0)
  • 2021-01-03 20:30

    I was facing the same error and I restarted R session, it worked for me.

    0 讨论(0)
提交回复
热议问题