Description Usage Arguments Value Author(s) Examples
Stage-2 data reconstruction by regular or sparse constrained principal component analysis (PCA).
1 2 3 4 5 6 7 8 9  | reconByUnsupervised(
  trainDataList,
  testDataList,
  typeMode = "regular",
  topPC = 1,
  innerCore = MulticoreParam(),
  outFileA = NULL,
  outFileB = NULL
)
 | 
trainDataList | 
 The input training data list containing ordered collections of matrices.  | 
testDataList | 
 The input test data list containing ordered collections of matrices.  | 
typeMode | 
 The type of PCA prediction mode. Available options are c('regular', 'sparse'). (Default: regular)  | 
topPC | 
 The number of top PCs selected. The default is 1, i.e. the first PC.  | 
innerCore | 
 The number of cores used for computation.  | 
outFileA | 
 The file name of stage-2 training data with the '.rds' file extension. If it's provided, then the result will be saved in this file. The default is NULL.  | 
outFileB | 
 The file name of stage-2 training data with the '.rds' file extension. If it's provided, then the result will be saved in this file. The default is NULL.  | 
The predicted stage-2 training data and also stage-2 test data if 'testDataList' provided. If outFileA and outFileB are provided then the results will be stored in the files.
Junfang Chen
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22  |  
## Load data  
methylfile <- system.file('extdata', 'methylData.rds', package='BioMM')  
methylData <- readRDS(methylfile)    
## Annotation file   
probeAnnoFile <- system.file('extdata', 'cpgAnno.rds', package='BioMM')  
## Mapping CpGs into Pathways
featureAnno <- readRDS(file=probeAnnoFile)  
## Mapping CpGs into Pathways
featureAnno <- readRDS(system.file("extdata", "cpgAnno.rds", package="BioMM")) 
pathlistDB <- readRDS(system.file("extdata", "goDB.rds", package="BioMM")) 
head(featureAnno)   
dataList <- omics2pathlist(data=methylData, pathlistDB, featureAnno, 
                           restrictUp=100, restrictDown=10, minPathSize=10) 
length(dataList) 
library(BiocParallel)
param <- MulticoreParam(workers = 10) 
stage2data <- reconByUnsupervised(trainDataList=dataList, testDataList=NULL, 
                             typeMode='regular', topPC=1,  
                             innerCore=param, outFileA=NULL, outFileB=NULL) 
print(dim(stage2data))
print(head(stage2data[,1:5]))
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.