Description Usage Arguments Details Value Author(s) See Also Examples
View source: R/read_simple.R View source: R/read_simple.R
OBSOLETE : please refer to documentation for "VCF_snpmat_diplo_bial_geno_filtered" to
find out about their replacements.
Reads biallelic SNP data in different representations into pre-allocated matrices.
1 2 3 4 5 | VCF_read_snp_diplo_bial_int_altpresence( vcffh , mat )
VCF_read_snp_diplo_bial_int_nuclcodes( vcffh , mat )
VCF_read_snp_diplo_bial_str_01( vcffh , mat )
VCF_read_snp_diplo_bial_str_allelechars( vcffh , mat )
VCF_read_snp_diplo_bial_str_nuclcodes( vcffh , mat )
|
vcffh |
VCF file handle as returned by vcf_open |
mat |
A matrix of either integer or string type, corresponding to _str_ or _int_ named methods |
OBSOLETE : please refer to documentation for "VCF_snpmat_diplo_bial_geno_filtered" to
find out about their replacements.
Prerequisites are: - a valid, open VCF file handle, passed as vcffh - a valid sample selection (vcf_getsamples,vcf_getselectedsamples,vcf_selectsmaples) - a properly set region (vcf_setregion) - and a result matrix, mat.
The matrix will be filled with allele data in one of 4 encodings and needs to be of either integer or character data type, both depending on the called function (VCF_..._int_... or VCF_..._str_...) . Each column corresponds to a SNP locus and each row to a sample. The number of matrix columns determines the maximum number of SNP loci that are parsed from the VCF. Column names are set to the position of the SNP, the row names are named after the samples they represent. There must be at least as many rows as selected samples. Unused rows will be filled with default (N) data. If there are not enough SNPs to fill all columns, the unused columns will be numbered with -1 and filled with N or -1.
VCF data is required to be diploid.
Representations:
int_altpresence : 0 if genotype is REF/REF, 1 if not
int_nuclcodes : integers, two-digit numbers: 11=TT, 12=TC, 13=TG, 14=TA, 15=TN, 21=CT, etc. (1=T, 2=C, 3=G, 4=A, 5=N)
str_01 : string, either 00, 01, 10 or 11 : 00=ref/ref, 11=alt/alt, 10=alt/ref, 01=ref/alt
str_allelechars : string, nucleotides of both chromosomes (no indication of reference allele)
str_nuclcodes : string, two-digit numbers: 11=TT, 12=TC, 13=TG, 14=TA, 15=TN, 21=CT, etc. (1=T, 2=C, 3=G, 4=A, 5=N)
TRUE or FALSE
Ulrich Wittelsbuerger
VCF_snpmat_diplo_bial_geno_filtered
1 | warning("These functions are obsolete! Consult VCF_snpmat_diplo_bial_geno_filtered etc.")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.