Description Usage Arguments Value Examples
The function plotAndCalculateWeakAndStrongGenotype
finds the strongest and weakest genotypes based on reads extracted around each region. Strong and weak genotypes are found using the reads extracted from SNPhood and their corresponding genotypes as found by the function associateGenotypes
Note the reads have to be merged using the function mergeReadGroups
before running this function.
1 2 | plotAndCalculateWeakAndStrongGenotype(SNPhood.o, normalize = TRUE,
nClustersVec = 3, fileToPlot = NULL, verbose = FALSE)
|
SNPhood.o |
Object of class |
normalize |
Logical(1). Default TRUE. Should a normalization be done on the counts/enrichments values before clustering? If set to TRUE, a normalization procedure based on subtracting the mean dividing by standard deviation for each region is performed. For more details, see the vignette. |
nClustersVec |
Numeric. Default 2. The number of clusters the data should be divided into. This can either be a vector or a single value. if multiple clusters are specified, multiple clustering analyses will be performed and for each of them, a plot is produced. make sure to specify the parameter fileToPlot in that case; otherwise, only the last plot may be visible. |
fileToPlot |
Character(1) or |
verbose |
Logical(1). Default FALSE. Should the verbose mode (i.e., diagnostic messages during execution of the script) be enabled? |
Modified SNPhood
object with the results of the analysis stored in the object.
Specifically, a matrix for average reads per SNP for datasets which have strong and weak genotypes, respectively, are stored in the
slot additionalResults$genotype.
The SNPs which have invariant genotypes across all the samples being analyzed are also saved.
In addition, clustering on the strong and weak genotype read mateices are reportd as in the function plotAndClusterMatrix
.
1 2 3 4 | data(SNPhood.o, package="SNPhood")
SNPhood_merged.o = mergeReadGroups(SNPhood.o)
SNPhood_merged.o = plotAndCalculateWeakAndStrongGenotype(SNPhood_merged.o, nClustersVec = 6)
SNPhood_merged.o = plotAndCalculateWeakAndStrongGenotype(SNPhood_merged.o, nClustersVec = 2:6, verbose = FALSE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.