The Quantile-Quantile Plot or (Q-Q Plot) is defined as a value of two variables that are plotted corresponding to each other and check whether the distributions of two variables are similar or not with respect to the locations.

function in R Language is used to draw a Q-Q Line Plot.**qqline()**

Syntax:qqline(x, y, col)

Parameters:

x, y:X and Y coordinates of plot

col:It defines color

Returns:A QQ Line plot of the coordinates provided

**Example 1:** Implementation of Basic QQplot Interpretation

`# Set seed for reproducibility ` `set.seed` `(500) ` ` ` `# Create random normally distributed values ` `x <- ` `rnorm` `(1200) ` ` ` `# QQplot of normally distributed values ` `qqnorm` `(x) ` ` ` `# Add qqline to plot ` `qqline` `(x, col = ` `"darkgreen"` `) ` |

*chevron_right*

*filter_none*

**Output:**

Above is a representation of QQplot of Normally Distributed Random Numbers.

**Example 2:** Implementation of QQplot of Logistically Distributed Values

`# Set seed for reproducibility ` ` ` `# Random values according to logistic distribution ` `# QQplot of logistic distribution ` `y <- ` `rlogis` `(800) ` ` ` `# QQplot of normally distributed values ` `qqnorm` `(y) ` ` ` `# Add qqline to plot ` `qqline` `(y, col = ` `"darkgreen"` `) ` |

*chevron_right*

*filter_none*

**Output:**

Above is the Q-Q Plot of theoretical quantiles.

## Recommended Posts:

- Set Aspect Ratio of Scatter Plot and Bar Plot in R Programming - Using asp in plot() Function
- Addition of more points to a Plot in R Programming - points() Function
- Addition of Lines to a Plot in R Programming - lines() Function
- Add Color Between Two Points of Kernel Density Plot in R Programming - Using with() Function
- Plot Arrows Between Points in a Graph in R Programming - arrows() Function
- Plot a Geometric Distribution Graph in R Programming - dgeom() Function
- Create a Plot Matrix of Scatterplots in R Programming - pairs() Function
- Adding axis to a Plot in R programming - axis () Function
- Adding Straight Lines to a Plot in R Programming - abline() Function
- Plotting of Data using Generic plots in R Programming - plot() Function
- Draw Line Segments between Particular Points in R Programming - segments() Function
- Draw a Polygon between specified points in R Programming - polygon() Function
- Check if a Function is a Primitive Function in R Programming - is.primitive() Function
- Compute Density of the Distribution Function in R Programming - dunif() Function
- Apply a Function over a List of elements in R Programming - lapply() Function
- Search the Interval for Minimum and Maximum of the Function in R Programming - optimize() Function
- Compute the Natural Logarithm of the Absolute Value of Gamma Function in R Programming - lgamma() Function
- Compute the Logarithmic Derivative of the gamma Function in R Programming - digamma() Function
- Compute the Second Derivative of the Logarithmic value of the gamma Function in R Programming - trigamma() Function
- Get the List of Arguments of a Function in R Programming - args() Function

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.