datavisupca: PCA visualization of your 'MSnSet' data

View source: R/datavisupca.R

datavisupcaR Documentation

PCA visualization of your MSnSet data

Description

datavisupca allows you to visualize the PCA plot of your data, clustered and not clustered on the same figure. You can also choose to not see the plot and only get back your clustered data. The clustering method available are from the pRoloc package (Laurent Gatto and al.).

Usage

datavisupca(
  object,
  mfcol = "markers",
  method = "knn",
  ax = c(1, 2),
  sh.gr = TRUE,
  tm = 5,
  cv = 5
)

Arguments

object

A MSnSet object

mfcol

The name of the column which contains the markers from your data

method

The clustering method, available : svm, ksvm, knn, perTurbo, nnet (neural network), rf (random forest), naiveBayes, xgboost, CPA (constrained proportionate assignment), CNN or SpatialTransformer.

ax

A numeric vector of length 2, the axes on which you want to see the PCA plot (depend of the number of fraction of the data)

sh.gr

A logical argument, to show or not the plot. if FALSE, return only a MSnSet object : your data + the clustering information

tm

An integer corresponding to the times parameter of clustering optimization functions from pRoloc package

cv

An integer corresponding to the cross validation parameter of clustering optimization functions from pRoloc package

Value

A list containing the two PCA plots on the same figure (clustered and not clustered) and the clustered MSnSet object if sh.gr = TRUE else, it return only the clustered MSnSet object

See Also

svmOptimisation from Roloc package and fviz_pca_ind from factoextra package

Examples


library(pRolocExtra)
datavisupca(tan2009r1)

mgerault/pRolocExtra documentation built on Sept. 15, 2022, 9:26 a.m.