Learn R Programming

⚠️There's a newer version (0.36) of this package.Take me there.

R/qtl2

Karl Broman

R/qtl2 (aka qtl2) is a reimplementation of the QTL analysis software R/qtl, to better handle high-dimensional data and complex cross designs.

Also see the related packages, qtl2convert (for converting data among the R/qtl2, DOQTL, and R/qtl formats), qtl2fst (for storing genotype probabilities on disk), and qtl2ggplot (for ggplot2-based data visualizations).


Installation

Install R/qtl2 from CRAN:

install.packages("qtl2")

Documentation


Citation

To cite R/qtl2 in publications, use:

Broman KW, Gatti DM, Simecek P, Furlotte NA, Prins P, Sen Ś, Yandell BS, Churchill GA (2019) R/qtl2: software for mapping quantitative trait loci with high-dimensional data and multi-parent populations. Genetics 211:495-502 doi:10.1534/genetics.118.301595


License

Licensed under GPL-3.

Copy Link

Version

Install

install.packages('qtl2')

Monthly Downloads

625

Version

0.32

License

GPL-3

Issues

Pull Requests

Stars

Forks

Maintainer

Karl Broman

Last Published

April 22nd, 2023

Functions in qtl2 (0.32)

bayes_int

Calculate Bayes credible intervals
calc_raw_geno_freq

Calculate genotype frequencies from raw SNP genotypes
cbind.calc_genoprob

Join genotype probabilities for different chromosomes
cbind.scan1

Join genome scan results for different phenotypes.
calc_het

Calculate heterozygosities
calc_grid

Calculate indicators of which marker/pseudomarker positions are along a fixed grid
clean

Clean an object
chr_lengths

Calculate chromosome lengths
calc_raw_het

Calculate estimated heterozygosity from raw SNP genotypes
clean_genoprob

Clean genotype probabilities
batch_cols

Batch columns by pattern of missing values
calc_kinship

Calculate kinship matrix
clean_scan1

Clean scan1 output
basic_summaries

Basic summaries of a cross2 object
calc_raw_maf

Calculate minor allele frequency from raw SNP genotypes
check_cross2

Check a cross2 object
calc_sdp

Calculate strain distribution pattern from SNP genotypes
chisq_colpairs

Chi-square test on all pairs of columns
calc_raw_founder_maf

Calculate founder minor allele frequencies from raw SNP genotypes
cbind.scan1perm

Combine columns from multiple scan1 permutation results
create_gene_query_func

Create a function to query genes
count_xo

Count numbers of crossovers
find_peaks

Find peaks in a set of LOD curves
decomp_kinship

Calculate eigen decomposition of kinship matrix
cbind.viterbi

Join viterbi results for different chromosomes
cbind_expand

Combine matrices by columns, expanding and aligning rows
create_snpinfo

Create snp information table for a cross
drop_markers

Drop markers from a cross2 object
create_variant_query_func

Create a function to query variants
find_marker

Find markers by chromosome position
find_markerpos

Find positions of markers
find_index_snp

Find name of indexed snp
insert_pseudomarkers

Insert pseudomarkers into a marker map
genoprob_to_alleleprob

Convert genotype probabilities to allele probabilities
genoprob_to_snpprob

Convert genotype probabilities to SNP probabilities
fit1

Fit single-QTL model at a single position
interp_genoprob

Interpolate genotype probabilities
find_map_gaps

Find gaps in a genetic map
compare_geno

Compare individuals' genotype data
n_missing

Count missing genotypes
max_compare_geno

Find pair with most similar genotypes
max_scan1

Find position with maximum LOD score
cbind.sim_geno

Join genotype imputations for different chromosomes
compare_maps

Compare two marker maps
convert2cross2

Convert R/qtl cross object to new format
plot_peaks

Plot QTL peak locations
drop_nullmarkers

Drop markers with no genotype data
get_common_ids

Get common set of IDs from objects
est_herit

Estimate heritability with a linear mixed model
plot_pxg

Plot phenotype vs genotype
align_scan1_map

Internal functions
compare_genoprob

Compare two sets of genotype probabilities
qtl2-package

qtl2: Quantitative Trait Locus Mapping in Experimental Crosses
plot_coef

Plot QTL effects along chromosome
rbind.calc_genoprob

Join genotype probabilities for different individuals
qtl2version

Installed version of R/qtl2
probs_to_grid

Subset genotype probability array to pseudomarkers on a grid
plot_scan1

Plot a genome scan
find_ibd_segments

Find IBD segments for a set of strains
interp_map

Interpolate between maps
est_map

Estimate genetic maps
plot_sdp

plot strain distribution patterns for SNPs
pull_genoprobint

Pull genotype probabilities for an interval
guess_phase

Guess phase of imputed genotypes
scan1max

Maximum LOD score from genome scan with a single-QTL model
rbind.scan1

Join genome scan results for different chromosomes.
get_x_covar

Get X chromosome covariates
scan1perm

Permutation test for genome scan with a single-QTL model
sim_geno

Simulate genotypes given observed marker data
maxlod

Overall maximum LOD score
maxmarg

Find genotypes with maximum marginal probabilities
lod_int

Calculate LOD support intervals
plot_genoprob

Plot genotype probabilities for one individual on one chromosome.
plot_genoprobcomp

Plot comparison of two sets of genotype probabilities
locate_xo

Locate crossovers
index_snps

Create index of equivalent SNPs
smooth_gmap

Smooth genetic map
rbind.scan1perm

Combine data from scan1perm objects
pull_genoprobpos

Pull genotype probabilities for a particular position
invert_sdp

Calculate SNP genotype matrix from strain distribution patterns
scan1blup

Calculate BLUPs of QTL effects in scan along one chromosome
plot_compare_geno

Plot of compare_geno object.
scan1coef

Calculate QTL effects in scan along one chromosome
map_to_grid

Subset a map to positions on a grid
mat2strata

Define strata based on rows of a matrix
plot_onegeno

Plot one individual's genome-wide genotypes
print.cross2

Print a cross2 object
plot_genes

Plot gene locations for a genomic interval
plot_lodpeaks

Plot LOD scores vs QTL peak locations
viterbi

Calculate most probable sequence of genotypes
subset.viterbi

Subsetting Viterbi results
subset.sim_geno

Subsetting imputed genotypes
write_control_file

Write a control file for QTL data
pull_markers

Drop all but a specified set of markers
print.summary.scan1perm

Print summary of scan1perm permutations
rbind.viterbi

Join Viterbi results for different individuals
rbind.sim_geno

Join genotype imputations for different individuals
plot_snpasso

Plot SNP associations
read_csv

Read a csv file
read_cross2

Read QTL data from files
read_csv_numer

Read a csv file that has numeric columns
reduce_markers

Reduce markers to a subset of more-evenly-spaced ones
replace_ids

Replace individual IDs
predict_snpgeno

Predict SNP genotypes
read_pheno

Read phenotype data
recode_snps

Recode SNPs by major allele
subset_scan1

Subset scan1 output
scan1

Genome scan with a single-QTL model
scale_kinship

Scale kinship matrix
summary.cross2

Summary of cross2 object
sdp2char

Convert strain distribution patterns to character strings
scan1snps

Single-QTL genome scan at imputed SNPs
xpos_scan1

Get x-axis position for genomic location
subset.calc_genoprob

Subsetting genotype probabilities
reduce_map_gaps

Reduce the lengths of gaps in a map
subset.cross2

Subsetting data for a QTL experiment
zip_datafiles

Zip a set of data files
top_snps

Create table of top snp associations
unsmooth_gmap

Unsmooth genetic map
summary_compare_geno

Basic summary of compare_geno object
summary_scan1perm

Summarize scan1perm results
calc_entropy

Calculate entropy of genotype probability distribution
calc_geno_freq

Calculate genotype frequencies
add_threshold

Add thresholds to genome scan plot
batch_vec

Split vector into batches
CCcolors

Collaborative Cross colors
calc_genoprob

Calculate conditional genotype probabilities
calc_errorlod

Calculate genotyping error LOD scores