View source: R/onemap_read_vcfR.R
onemap_read_vcfR | R Documentation |
Converts data from a vcf file to onemap initial object, while identify the appropriate marker segregation patterns.
onemap_read_vcfR( vcf = NULL, vcfR.object = NULL, cross = c("outcross", "f2 intercross", "f2 backcross", "ri self", "ri sib"), parent1 = NULL, parent2 = NULL, f1 = NULL, only_biallelic = TRUE, output_info_rds = NULL, verbose = TRUE )
vcf |
string defining the path to VCF file; |
vcfR.object |
object of class vcfR; |
cross |
type of cross. Must be one of: |
parent1 |
|
parent2 |
|
f1 |
|
only_biallelic |
if TRUE (default) only biallelic markers are considered, if FALSE multiallelic markers are included. |
output_info_rds |
define a name for the file with alleles information. |
verbose |
A logical, if TRUE it output progress status information. |
Only biallelic SNPs and indels for diploid variant sites are considered.
Genotype information on the parents is required for all cross types. For full-sib progenies, both outbred parents must be genotyped. For backcrosses, F2 intercrosses and recombinant inbred lines, the original inbred lines must be genotyped. Particularly for backcross progenies, the recurrent line must be provided as the first parent in the function arguments.
Marker type is determined based on parental genotypes. Variants for which parent genotypes cannot be determined are discarded.
Reference sequence ID and position for each variant site are also stored.
An object of class onemap
, i.e., a list with the following
components:
geno |
a matrix with integers indicating the genotypes read for each marker. Each column contains data for a marker and each row represents an individual. |
n.ind |
number of individuals. |
n.mar |
number of markers. |
segr.type |
a vector with the
segregation type of each marker, as |
segr.type.num |
a
vector with the segregation type of each marker, represented in a
simplified manner as integers, i.e. 1 corresponds to markers of type
|
input |
the name of the input file. |
n.phe |
number of phenotypes. |
pheno |
a matrix with phenotypic values. Each column contains data for a trait and each row represents an individual. |
error |
matrix containing HMM emission probabilities |
Cristiane Taniguti, chtaniguti@tamu.edu
read_onemap
for a description of the output object of class onemap.
data <- onemap_read_vcfR(vcf=system.file("extdata/vcf_example_out.vcf.gz", package = "onemap"), cross="outcross", parent1=c("P1"), parent2=c("P2"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.