0

Quick question, I'm using an older version of R Studio - R 3.2.3 - and some newer packages require a newer version. Specifically, I want the wordcloud package, so is there a way to install an older version that is compatible with my version of R? I couldn't find a simple straight-to-the-point answer online and I'm on a bit of a time crunch since I need to create some wordclouds.

I'm using a Windows machine.

Mike
  • 2,017
  • 6
  • 26
  • 53

1 Answers1

3

There are two ways you can install older packages in R.

Using devtools

Use the following code, updating the 2.2 with the version of wordcloud that you require.

require(devtools)
install_version("wordcloud", version = "2.2", repos = "http://cran.us.r-project.org")

Installing older packages from source

Equally you can install older packages directly from a URL as below.

wordcloudURL <- "https://cran.r-project.org/src/contrib/Archive/wordcloud/wordcloud_2.2.tar.gz"
install.packages(wordcloudURL, repos=NULL, type="source")

The URLs for older versions of wordcloud are available here.

figurine
  • 746
  • 9
  • 22
  • 1
    There is no need to copy/paste solutions from dupes, rather point and close the question with the appropriate dupe. – David Arenburg Dec 18 '16 at 00:21
  • I didn't copy and paste anything, just answered the question, but ok. – figurine Dec 18 '16 at 00:25
  • 1
    Yes you did. The `install.packages(packageurl, repos=NULL, type="source")` line is an exact copy/paste You can see it by the lack of spaces around the `=` sign- this is Thomases coding style. The `install_version` is a copy paste from the other answer- again you can see this by the spaces around the `=` sign- this is shadows coding style. It is clear that this wasn't written by the same person- a single person doesn't use two different coding styles (especially in the same answer). If you insist on copy/pasting, you could at least provide proper attribution. – David Arenburg Dec 18 '16 at 07:19
  • I didn't copy paste, I'm an inexperienced and inconsistent programmer but I didn't copy and paste. I didn't even check for duplicates before posting, but obviously you know better than me what I did. – figurine Dec 18 '16 at 09:09