validateRunObservation {methylInheritance} | R Documentation |
Validation of some parameters of the
runObservation
function
Description
Validation of some parameters needed by the public
runObservation
function.
Usage
validateRunObservation(methylKitData, type, outputDir, nbrCoresDiffMeth,
minReads, minMethDiff, qvalue, maxPercReads, destrand,
minCovBasesForTiles, tileSize, stepSize, vSeed, restartCalculation,
saveInfoByGeneration)
Arguments
methylKitData |
a list of methylRawList entries or the
name of the RDS file containing the list. Each
methylRawList contains all the methylRaw entries related to
one generation (first entry = first generation, second entry = second
generation, etc..). The number of generations must correspond to the number
of entries in the methylKitData . At least 2 generations
must be present to calculate the conserved elements. More information can
be found in the methylKit package.
|
type |
One of the "sites","tiles" or "both" strings. Specifies the type
of differentially methylated elements should be returned. For
retrieving differentially methylated bases type="sites"; for
differentially methylated regions type="tiles". Default: "both".
|
outputDir |
a string, the name of the directory that will contain
the results of the permutation. If the directory does not exist, it will
be created.
|
nbrCoresDiffMeth |
a positive integer , the number of cores
to use for parallel differential methylation calculations.Parameter
used for both sites and tiles analysis. The parameter
corresponds to the num.cores parameter in
the methylKit package.
|
minReads |
a positive integer Bases and regions having lower
coverage than this count are discarded. The parameter
correspond to the lo.count parameter in the methylKit
package.
|
minMethDiff |
a positive double betwwen [0,100], the absolute
value of methylation percentage change between cases and controls. The
parameter correspond to the difference parameter in
the methylKit package.
|
qvalue |
a positive double betwwen [0,1], the cutoff
for qvalue of differential methylation statistic.
|
maxPercReads |
a double between [0,100], the percentile of read
counts that is going to be used as upper cutoff. Bases ore regions
having higher
coverage than this percentile are discarded. Parameter used for both CpG
sites and tiles analysis. The parameter
correspond to the hi.perc parameter in the methylKit package.
|
destrand |
a logical , when TRUE will merge reads on both
strands of a CpG dinucleotide to provide better coverage. Only advised
when looking at CpG methylation. Parameter used for both CpG
sites and tiles analysis.
|
minCovBasesForTiles |
a non-negative integer , the minimum
number of bases to be covered in a given tiling window. The parameter
corresponds to the cov.bases parameter in the package
methylKit . Only used when doingTiles =
TRUE . Default: 0 .
|
tileSize |
a positive integer , the size of the tiling window.
The parameter corresponds to the win.size parameter in
the methylKit package. Only
used when doingTiles = TRUE .
|
stepSize |
a positive integer , the step size of tiling windows.
The parameter corresponds to the stepSize parameter in
the methylKit package. Only
used when doingTiles = TRUE .
|
vSeed |
a integer , a seed used when reproducible results are
needed. When a value inferior or equal to zero is given, a random integer
is used.
|
restartCalculation |
a logical , when TRUE , only
permutations that don't have an associated RDS result file are run. Useful
to restart a permutation analysis that has been interrupted.
|
saveInfoByGeneration |
a logical , when TRUE , the
information about differentially methylated sites and tiles for each
generation is saved in a RDS file. The information is saved in a different
file for each permutation. The files are only saved when the
outputDir is not NULL .
|
Value
0
indicating that all parameters validations have been
successful.
Author(s)
Astrid Deschenes
Examples
## Load dataset
data(samplesForTransgenerationalAnalysis)
## The function returns 0 when all paramaters are valid
methylInheritance:::validateRunObservation(
methylKitData = samplesForTransgenerationalAnalysis, type = "sites",
outputDir = "test", nbrCoresDiffMeth = 1, minReads = 10,
minMethDiff = 25, qvalue = 0.01,
maxPercReads = 99.9, destrand = TRUE, minCovBasesForTiles = 10,
tileSize = 1000, stepSize = 500, vSeed = 12, restartCalculation = TRUE,
saveInfoByGeneration = FALSE)
## The function raises an error when at least one paramater is not valid
## Not run: methylInheritance:::validateRunObservation(
methylKitData = samplesForTransgenerationalAnalysis,
type = "tiles", outputDir = "test_02", nbrCoresDiffMeth = 1,
minReads = "HI", minMethDiff = 25, qvalue = 0.01,
maxPercReads = 99.9, destrand = TRUE, minCovBasesForTiles = 10,
tileSize = 1000, stepSize = 500, vSeed = 12, restartCalculation = FALSE,
saveInfoByGeneration = FALSE)
## End(Not run)
[Package
methylInheritance version 1.14.0
Index]