Description Usage Arguments Value
Input the split matrix where rows that once had multiple annotations on single line are now represented on multiple lines. For the sites that once were multiallelic sites and are now represented as biallelic, thus function will change the contents of varmat_code such that the alternative allele(s) are 0. For example, T -> G, C is split into two lines: T -> G and T -> C. In the code matrix, turn the codes correspoding to the allele C in the row T -> G to 0 and the codes corresponding to the allele G in the row T -> C to 0.
1 2 3 4 5 6 7 | remove_alt_allele_code_from_split_rows(
varmat_code_split,
varmat_allele_split,
ref,
var,
rows_with_mult_var_allele_log
)
|
varmat_code_split |
- data.frame where the rows are variants (numeric description variants: numbers ranging from -4 to 3), the columns are genomes, and the row.names are annotations, and each line has a single annotation |
varmat_allele_split |
- data.frame where the rows are variants (character description variants: A,C,T,G,N,-), the columns are genomes, and the row.names are annotations, and each line has a single annotation |
ref |
- character vector length nrow(varmat_code_split) = nrow(varmat_allele_split) indicating the reference allele in terms of the positive strand |
var |
- character vector length nrow(varmat_code_split) = nrow(varmat_allele_split) indicating the variant allele in terms of the positive strand |
rows_with_mult_var_allele_log |
- logical vector length nrow(varmat_code_split) = nrow(varmat_allele_split) indicating which rows are multiallelic sites |
- varmat_code - data.frame where the rows are variants (numeric description variants: numbers ranging from -4 to 3), the columns are genomes, and the row.names are annotations, and each line has a single annotation where the alternative/minor allele in a biallelic-represrentation of a multiallelic site is now 0
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.