R (programming language): Difference between revisions

Content deleted Content added
m Modeling and plotting: CE image captions
Line 129:
{{Main|R package}}
 
[[File:Ggplot2 PlantGrowth violin plot.svg|alt=refer to caption|thumb|A [[Violinviolin plot]] created fromwith the R visualization package [[ggplot2]] for data visualization ]]
[[R package]]s are collections of functions, documentation, and data that expand R.<ref name="rds_pagexvii">{{cite book
| last1 = Wickham
Line 366:
 
=== Modeling and plotting ===
[[File:Plots from lm example.svg|right|thumb|200px|Diagnostic plots from plottingvisualizing a "model" object (q.v. "the <code>plot.lm()"</code> function). Notice the mathematicalMathematical notation is allowed in labels, as shown in the (lower left plot).]]
The R language has built-in support for [[data modeling]] and graphics. The following example shows how R can generate and plot a [[linear model]] with residuals.
<syntaxhighlight lang="r">