get_proportion_snp_sets | R Documentation |
I like this function. It generates an exhaustive catalog of the snps by chromosome for all the various categories as defined by factor.
get_proportion_snp_sets(
snp_expt,
factor = "pathogenstrain",
stringency = NULL,
do_save = FALSE,
savefile = "variants.rda",
minmax_cutoff = 0.05,
hetero_cutoff = 0.3
)
snp_expt |
Expressionset of variants. |
factor |
Use this metadata factor to split the data. |
stringency |
Allow for some wiggle room in the calls. |
do_save |
Save the results to an rda fil. |
savefile |
This is redundant with do_save. |
minmax_cutoff |
Cutoffs used to define homozygous vs. no-observation. |
hetero_cutoff |
Cutoff to define heterozygous vs. observed/homozygous |
A funky list by chromosome containing: 'medians', the median number of hits / position by sample type; 'possibilities', the; 'intersections', the groupings as detected by Vennerable; 'chr_data', the raw data; 'set_names', a character list of the actual names of the groupings; 'invert_names', the opposite of set_names which is to say the names of groups which do _not_ include samples x,y,z; 'density', a list of snp densities with respect to chromosomes. Note that this last one is approximate as I just calculate with the largest chromosome position number, not the explicit number of nucleotides in the chromosome.
[medians_by_factor()]
## Not run:
expt <- create_expt(metadata, gene_information)
snp_expt <- count_expt_snps(expt)
snp_sets <- get_snp_sets(snp_expt, factor = "condition")
## This assumes a column in the metadata for the expt named 'condition'.
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.