Title: | Parallel implementation of the "segment" function of package "DNAcopy" |
---|---|
Description: | Parallelized version of the "segment" function from Bioconductor package "DNAcopy", utilizing multi-core computation on host CPU |
Authors: | Alex Krasnitz, Guoli Sun |
Maintainer: | Guoli Sun <[email protected]> |
License: | GPL-2 |
Version: | 2.0 |
Built: | 2024-11-26 05:22:14 UTC |
Source: | https://github.com/cran/ParDNAcopy |
segment
function of DNAcopy
There are three key differences between this function and the original
segment
function of package DNAcopy
. First, the execution can be
parallelized, either by using multiple cores of the present host or by
invoking a grid engine to run on multiple hosts. Secondly, random number
generator may be re-initialized, with the same seed, for each sample. Finally,
there is a "skinny" option for the value, i.e., a DNAcopy
object with no
data
item.
parSegment(CNAobj, ranseed = NULL, distrib = c("vanilla", "Rparallel"), njobs = 1, out = c("full", "skinny"), ...)
parSegment(CNAobj, ranseed = NULL, distrib = c("vanilla", "Rparallel"), njobs = 1, out = c("full", "skinny"), ...)
CNAobj |
An object of class |
ranseed |
A single integer to seed the random number generator. |
distrib |
One of "vanilla" (default) and "Rparallel" to choose a parallelization option: no parallelization ("vanilla"), parallelization on multiple cores of the local host ("Rparallel"). |
njobs |
An integer specifying the desired number of parallel jobs. |
out |
One of "full" (default) or "skinny" to specify the form of the value, an object
of class |
... |
Arguments other than |
An object of class DNAcopy
. If out == "skinny"
the data
item of the value will not be returned in order to reduce the memory use.
Alex Krasnitz
Package DNAcopy
.
data(coriell) #prepare data for segmentation CNA.object <- CNA(genomdat=coriell[,c(4,5)],coriell$Chromosome,coriell$Position, data.type="logratio",sampleid=dimnames(coriell)[[2]][4:5]) #equivalent to "segment" of DNAcopy parseg<-parSegment(CNA.object,undo.splits="sdundo") #Random number generator to be re-seeded for each sample parsegrep<-parSegment(CNA.object,ranseed=123,undo.splits="sdundo") #multi-core execution but the result should not change parsegrep1<-parSegment(CNA.object,ranseed=123,distrib="Rparallel",njobs=2, undo.splits="sdundo")
data(coriell) #prepare data for segmentation CNA.object <- CNA(genomdat=coriell[,c(4,5)],coriell$Chromosome,coriell$Position, data.type="logratio",sampleid=dimnames(coriell)[[2]][4:5]) #equivalent to "segment" of DNAcopy parseg<-parSegment(CNA.object,undo.splits="sdundo") #Random number generator to be re-seeded for each sample parsegrep<-parSegment(CNA.object,ranseed=123,undo.splits="sdundo") #multi-core execution but the result should not change parsegrep1<-parSegment(CNA.object,ranseed=123,distrib="Rparallel",njobs=2, undo.splits="sdundo")