I am trying to use a dataset in AER package but I can not use library("AER") because of the following errors:

install.packages("AER")
Installing package into ‘/home/naghme/R/x86_64-pc-linux-gnu-library/3.4’
(as ‘lib’ is unspecified)
Warning in install.packages :
  dependency ‘car’ is not available
trying URL 'https://cloud.r-project.org/src/contrib/AER_1.2-6.tar.gz'
Content type 'application/x-gzip' length 2192380 bytes (2.1 MB)
==================================================
downloaded 2.1 MB

ERROR: dependency ‘car’ is not available for package ‘AER’
* removing ‘/home/naghme/R/x86_64-pc-linux-gnu-library/3.4/AER’
Warning in install.packages :
  installation of package ‘AER’ had non-zero exit status

The downloaded source packages are in
    ‘/tmp/Rtmpb7sbO6/downloaded_packages’


> library("AER")
Error in library("AER") : there is no package called ‘AER’

1 Answers

0
JeffR On

As stated at https://cran.r-project.org/web/packages/car/index.html, the car package has a dependency on R version 3.5.0 or greater. You need to update the version of R you are running.