View source: R/export.groups.R
export.groups | R Documentation |
Export clustering result of
ipcaps2
to text file called 'groups.txt'.
export.groups(result.dir, silence.mode = FALSE)
result.dir |
A result directory as the |
silence.mode |
To enable or disable silence mode. If silence mode is enabled, the fuction is processed without printing any message on the screen, and it is slightly faster. Default = TRUE. |
After running, this function exports the file called 'groups.txt' to the same result directory. If 'groups.txt' already exists in the result directory, the exported file is changed to 'groups1.txt', 'groups2.txt', 'groups3.txt', ..., accordingly.
A data frame of exported data containing 4 columns; group
,
node
, label
, row.number
, as described below for more
details:
group
represents group membership of IPCAPS2 result.
node
represents node numbers of IPCAPS2 result.
label
represents labels of rows in orginal input data.
row.number
represents row numbers of orginal input data.
# Importantly, bed file, bim file, and fam file are required # Use the example files embedded in the package BED.file <- system.file("extdata","ipcaps_example.bed",package="IPCAPS2") LABEL.file <- system.file("extdata","ipcaps_example_individuals.txt.gz",package="IPCAPS2") my.cluster <- ipcaps2(bed=BED.file, label.file=LABEL.file, lab.col=2, out=tempdir(), silence=TRUE, no.rep=1) #Here, to export the IPCAPS2 result to a text file exported.data <- export.groups(my.cluster$output.dir) print(dim(exported.data)) head(exported.data)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.