Description Usage Arguments Value Examples
View source: R/setupFeatureDB.R
Creates all the input files for the collection of features used in feature selection.
1 | setupFeatureDB(pheno, prepDir = tempdir())
|
pheno |
(data.frame) patient metadata. Must contain ID column |
prepDir |
(char) directory in which to setup database |
(data.frame) internal numerical id for patients (INTERNAL_ID) and user-provided ID (ID)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 | data(xpr,pheno)
pathwayList <- list(pathA=rownames(xpr)[1:10],pathB=rownames(xpr)[21:50])
dataList <- list(rna=xpr) #only one layer type
groupList <- list(rna=pathwayList) # group genes by pathways
makeNets <- function(dataList, groupList, netDir,...) {
netList <- makePSN_NamedMatrix(dataList[['rna']],
rownames(dataList[['rna']]),
groupList[['rna']],netDir,verbose=FALSE,
writeProfiles=TRUE,...)
unlist(netList)
}
tmpDir <- tempdir(); netDir <- paste(tmpDir,"nets",sep=getFileSep())
dir.create(netDir,recursive=TRUE)
pheno_id <- setupFeatureDB(pheno,netDir)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.