Understanding R packages
Packages are the most important aspect of the R language to create reproducible code and analysis. They are collections of R functions, data, and compiled code in a very standardized way. This makes it very easy to share them across R users and add new elements from others to already installed packages to take your R analysis to the next level. These packages can help to solve many tasks with R without having to write every single line of code on your own. If you take machine-learning algorithms for example, you can use implementations of these algorithms without the need to implement them line-by-line. Packages are mostly developed in R, but can also contain elements written in other languages such as Java or C++.
R already comes with some preinstalled packages like the base
package, which consists of the basic functions to make R a real language. There are many package resources on the Internet. The most important of these libraries for R is Comprehensive R Archive...