7
$\begingroup$

Duplicate thread: What R packages do you find most useful in your daily work?

Are there any R packages that are just plain good to have, regardless of the type of work you are doing? If so, what are these packages? If not, what packages do you find the most useful?

$\endgroup$
  • $\begingroup$ Debating making this Community Wiki - I really want to see what the first couple of answers are, first, though. If someone can provide a list of "must have" R packages, I'll probably accept that. If it begins to turn into a list of suggestions (or someone has an otherwise good reason), I'll CW this thing up. $\endgroup$ – Thomas Owens Aug 14 '10 at 1:40
  • 2
    $\begingroup$ I would say that this should be community wiki. $\endgroup$ – Shane Aug 14 '10 at 2:13
  • 7
    $\begingroup$ Possible duplicate: stats.stackexchange.com/questions/73/… $\endgroup$ – Shane Aug 14 '10 at 2:14
  • $\begingroup$ I agree it should be CW as the answer depends entirely on what you want to do. I load a lot of forecasting and time series packages, but others may not need them at all. $\endgroup$ – Rob Hyndman Aug 14 '10 at 5:13
  • 2
    $\begingroup$ I would close as a duplicate; also this question is within the scope of the site. $\endgroup$ – russellpierce Aug 17 '10 at 7:13

10 Answers 10

11
$\begingroup$

In a narrow sense, R Core has a recommendation: the "recommended" packages.

Everything else depends on your data analysis tasks at hand, and I'd recommend the Task Views at CRAN.

$\endgroup$
  • 1
    $\begingroup$ +1 Package demands heavily depend on each individual and I think Task Views are the way to start anyone. $\endgroup$ – Roman Luštrik May 11 '11 at 11:32
6
$\begingroup$

I imagine graphics and data manipulation are two things that are useful no matter what you are doing. Thus, I'd recommend:

  • ggplot2 (great graphics)
  • lattice (great graphics)
  • plyr (useful for data manipulation)
  • Hmisc (good for descriptive statistics and much more)
$\endgroup$
4
$\begingroup$

You can get user reviews of packages on crantastic

$\endgroup$
4
$\begingroup$

I would suggest using some of the packages provided by revolution R. In particular, I quite like the:

  • multicore package for parallel computing using shared memory processors
  • there optimized packages for matrices
$\endgroup$
3
$\begingroup$

This is definitely a question that doesn't have "an answer". It is completely dependent on what you want to do. That aside, I'll share the packages that I install as a standard with an R update...

install.packages(c("car","gregmisc","xtable","Design","Hmisc","psych",
                        "CCA", "fda", "zoo", "fields",
                      "catspec","sem","multilevel","Deducer","RQDA"))

and leave it to you to investigate those packages and see if they are valuable to you.

$\endgroup$
3
$\begingroup$

You can also take a look at Task views on CRAN and see if something suit your needs. I agree with @Jeromy for these must-have packages (for data manipulation and plotting).

$\endgroup$
3
$\begingroup$

If you are working with Latex, I recommend TikZ Device for outputting nice, Latex-formatted (like PSTricks) graphics. The output you get is text-based Latex code, which can be embedded with include(filename) into any figure environment.

Pros:

  • Same font in graphics as in your text
  • Professional look

Cons:

  • Takes longer to compile than PNG or PDF
  • for very complex R graphics, there are could be some display errors

https://github.com/Sharpie/RTikZDevice - Project, Packages available from CRAN and R-Forge

$\endgroup$
  • 1
    $\begingroup$ No disrespect, but that strikes me as entirely subjective. I have used latex for since the late 80s and R since the 90s yet I see no good reason to move away from embedding eps files. Everybody's mileage will differ here, and Thomas should maybe look at Task Views for particular problem domains. $\endgroup$ – Dirk Eddelbuettel Aug 14 '10 at 13:04
  • $\begingroup$ @Dirk: Good typography should not draw attention to its self and getting different text from LaTeX and R graphics is very visible (EPS output on the left, Sweave source code). Admittingly the example is a bit biased as no effort is made to customize the font used by eps. The point is that tikz should match the LaTeX document font, font size, letterspacing, kerning, ligaturing, etc. by default. If it doesn't, I consider it a bug. $\endgroup$ – Sharpie May 10 '11 at 21:54
3
$\begingroup$

I use lattice, ggplot2, lubridate, reshape, boot, e1071, car, forecast, and zoo a lot.

$\endgroup$
2
$\begingroup$

Jeromy mentioned my first pick: Lattice.

I also have found the doBy package and its summaryBy function to be insanely useful. They extend aggregate with a formula syntax that lets you aggregate multiple functions simultaneously in non-trivial ways. Great if you want, say, mean, std. dev., and length.

$\endgroup$
1
$\begingroup$

Some packages are very useful in R.

I will just recommand kernlab for Kernel-based Machine Learning Lab and e1071 for SVM and ggplot2 for graphics

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.