Plot principal component analysis
Plots a principal component analysis based on peptide or precursor intensities.
qc_pca( data, sample, grouping, intensity, condition, components = c("PC1", "PC2"), digestion = NULL, plot_style = "pca" )
data |
a data frame containing sample names, peptide or precursor identifiers, corresponding intensities and a condition column indicating e.g. the treatment. |
sample |
the column in the data data frame containing the sample name. |
grouping |
the column in the data data frame containing either precursor or peptide identifiers. |
intensity |
the column in the data data frame containing containing the corresponding intensity values for each peptide or precursor. |
condition |
the column in the data data frame indicating the treatment or condition for each sample. |
components |
character vector indicating the two components that should be displayed in the plot. By default these are PC1 and PC2. You can provide these using a character vector of the form c("PC1", "PC2"). |
digestion |
optional column indicating the mode of digestion (limited proteolysis or tryptic digest). |
plot_style |
character vector specifying what plot should be returned. If 'plot_style = "pca"' is selected the two PCA components supplied with the 'components' argument are plottet against each other. This is the default. 'plot_style = "scree"' returns a scree plot that displays the variance explained by each principal component in percent. The scree is useful for checking if any other than the default first two components should be plotted. |
A plotted principal component analysis showing PC1 and PC2
## Not run: qc_pca( data, sample = r_file_name, grouping = eg_precursor_id, intensity = normalised_intensity_log2, condition = r_condition, components = c("PC2", "PC3"), plot_style = "scree" ) ## End(Not run)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.