Can't Install Glmnet in R [Closed]

I am trying to install glmnet package (Version:2.0-5) in R version 3.3.1 (2016-06-21) on my windows 64-bit pc. But, I get following message.

installed.packages("glmnet")
 Package LibPath Version Priority Depends Imports LinkingTo Suggests Enhances License

 License_is_FOSS License_restricts_use OS_type Archs MD5sum NeedsCompilation Built

What could be wrong?

5

It hard to tell whether anything is wrong. The code:

installed.packages("glmnet")

... does not install anything. You should instead try this:

install.packages("glmnet", dependencies=TRUE)

The glmnet package has many dependencies. This is what I saw when I just installed it:

also installing the dependencies ‘mime’, ‘iterators’, ‘evaluate’, ‘formatR’, ‘highr’, ‘markdown’, ‘yaml’, ‘foreach’, ‘knitr’, ‘lars’

trying URL '
Content type 'application/x-gzip' length 24884 bytes (24 KB)
==================================================
downloaded 24 KB

trying URL '
Content type 'application/x-gzip' length 310135 bytes (302 KB)
==================================================
downloaded 302 KB

trying URL '
Content type 'application/x-gzip' length 45380 bytes (44 KB)
==================================================
downloaded 44 KB

trying URL '
Content type 'application/x-gzip' length 44156 bytes (43 KB)
==================================================
downloaded 43 KB

trying URL '
Content type 'application/x-gzip' length 28351 bytes (27 KB)
==================================================
downloaded 27 KB

trying URL '
Content type 'application/x-gzip' length 170142 bytes (166 KB)
==================================================
downloaded 166 KB

trying URL '
Content type 'application/x-gzip' length 168121 bytes (164 KB)
==================================================
downloaded 164 KB

trying URL '
Content type 'application/x-gzip' length 382270 bytes (373 KB)
==================================================
downloaded 373 KB

trying URL '
Content type 'application/x-gzip' length 940484 bytes (918 KB)
==================================================
downloaded 918 KB

trying URL '
Content type 'application/x-gzip' length 200050 bytes (195 KB)
==================================================
downloaded 195 KB

trying URL '
Content type 'application/x-gzip' length 1788514 bytes (1.7 MB)
==================================================
downloaded 1.7 MB


The downloaded binary packages are in
    /var/folders/68/vh2f8kzn09j8954r6q9100yh0000gn/T//Rtmp5fI1D2/downloaded_packages

Then nothing change in the result from your code. (I've never used the installed.packages function and so don't really know whether that is expected behavior.

> installed.packages("glmnet")
     Package LibPath Version Priority Depends Imports LinkingTo Suggests
     Enhances License License_is_FOSS License_restricts_use OS_type Archs MD5sum
     NeedsCompilation Built

So @bethanyP suggested looking at spelling (of what I'm not sure, perhaps just the function name). I looked at the help page for `installed.packages and now know why the result was uninformative with or without the presence of glmnet and that is that the first argument to installed packages is no a package name but rahter a library path. I don't have a library path by that name and so no packages were found in either case.

2
Sarah Jenkins

Sarah Jenkins

Senior Technology Editor & AI Specialist

Sarah Jenkins is a veteran tech journalist with over 12 years of experience covering artificial intelligence, mobile innovations, and digital ethics. Her insights have appeared in leading technology publications worldwide.

Share this article
Twitter Facebook Pinterest