bios2mds (version 1.2.2)

scree.plot: Plots the eingenvalues of an MDS analysis


Displays a bar plot of the eigenvalues obtained by MDS


scree.plot(x, lab = FALSE, title = NULL, xlim = NULL,
    ylim = NULL, new.plot = TRUE, pdf.file = NULL)



a numeric vector representing the raw or the relative eigenvalues of each component.


a boolean indicating whether bar labels should be displayed (TRUE) or not (FALSE). Default is FALSE.


a character string representing the title of the plot. Default is "Scree plot".


a numeric vector representing the range of the x values. Default is full range.


a numeric vector representing the range of the y values. Default is full range.


a boolean indicating whether a new graphical device should be created (TRUE) or not (FALSE). Default is TRUE.


a string indicating the name and directory of the pdf graph outfile. Default is NULL. If this parameter is not NULL, the parameter new.plot is inactivated.


Produces a bar plot on the active graphical device.


A scree plot is a method for determining the optimal number of components useful to describe the data in the context of metric MultiDimensional Scaling (MDS). The scree plot is an histogram showing the eigenvalues of each component. The relative eigenvalues express the ratio of each eigenvalue to the sum of the eigenvalues. The relative eigenvalue of a component gives the proportion of the data variance explained by this component.

The aim is to evaluate the number of components required to capture most information contained in the data. In a scree plot, the relative eigenvalues decrease when the component number increases. The 'elbow' of the plot determines the optimal number of components to describe the data (usually the components before the 'elbow').

See Also

plot.pca.scree function from bio3d package. goodness.metaMDS function from vegan package.


Run this code
# displaying the scree plot of the MDS analysis of human GPCRs
active <- gpcr$dif$sapiens.sapiens
mmds1 <- mmds(active, pc = 5)
scree.plot(mmds1$eigen.perc, lab = TRUE, title = "Scree plot of metric MDS")
# }

Run the code above in your browser using DataCamp Workspace