简体   繁体   中英

Error installing package readtext in R studio

I am using R studio on Ubuntu and I need to install the package "readtext", though when I do the command to install it:

install.packages("readtext")

I get the following error: ERROR: dependencies 'pdftools', 'streamR' are not available for package 'readtext' * removing '/home/ines/R/x86_64-pc-linux-gnu-library/3.6/readtext' Warning in install.packages: installation of package 'readtext' had non-zero exit status

The downloaded source packages are in '/tmp/RtmpytIy3B/downloaded_packages'

Can you help me please? Ines

The readtext package has a long list of Imports . Dependencies matter: you are will always be bound by the hardest constraint---which here appears to be that two of the listed direct Imports: .

Here I would recommend to work on the errors shown: as readtext depends on pdftools and streamr , you need to install these first. So try to work out if

 install.packages("pdftools")

(which will likely require system dependency libpoppler-cpp-dev to be installed first via sudo apt install libpoppler-cpp-dev ) and

 install.packages("streamR")

can be provided -- and then try readtext .

This is not an easy problem because of the many dependencies. There are ways to install pre-built binaries from CRAN packages on Ubuntu, but that is another topic.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM