Learn R Programming

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

gap (version 1.5-1)

Genetic Analysis Package

Description

As first reported [Zhao, J. H. 2007. "gap: Genetic Analysis Package". J Stat Soft 23(8):1-18. ], it is designed as an integrated package for genetic data analysis of both population and family data. Currently, it contains functions for sample size calculations of both population-based and family-based designs, probability of familial disease aggregation, kinship calculation, statistics in linkage analysis, and association analysis involving genetic markers including haplotype analysis with or without environmental covariates. Over years, the package has been developed in-between many projects hence also in line with the name (gap).

Copy Link

Version

Install

install.packages('gap')

Monthly Downloads

13,389

Version

1.5-1

License

GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

Last Published

January 22nd, 2023

Functions in gap (1.5-1)

LDkl

LD statistics for two multiallelic markers
KCC

Disease prevalences in cases and controls
ReadGRM

A function to read GRM file
METAL_forestplot

forest plot as R/meta's forest for METAL outputs
BFDP

Bayesian false-discovery probability
LD22

LD statistics for two diallelic markers
FPRP

False-positive report probability
AE3

AE model using nuclear family trios
MCMCgrm

Mixed modeling with genetic relationship matrices
ESplot

Effect-size plot
a2g

Allele-to-genotype conversion
WriteGRM

A function to write GRM file
WriteGRMBin

A function to write GRM binary file
asplot

Regional association plot
allele.recode

Allele recoding
ab

Test/Power calculation for mediating effect
ReadGRMBin

A function to read GRM binary files
snp.ES

Functions for single nucleotide polymorphisms (SNPs)
b2r

Obtain correlation coefficients and their variance-covariances
bt

Bradley-Terry model for contingency table
ccsize

Power and sample size for case-cohort design
circos.cis.vs.trans.plot

circos plot of cis/trans classification
chr_pos_a1_a2

SNP id by chr:pos+a1/a2
circos.mhtplot2

Another circos Manhattan plot
cis.vs.trans.classification

A cis/trans classifier
chow.test

Chow's test for heterogeneity in two regressions
cnvplot

genomewide plot of CNVs
comp.score

score statistics for testing genetic linkage of quantitative trait
circos.cnvplot

circos plot of CNVs.
circos.mhtplot

circos Manhattan plot with gene annotation
cs

Credible set
gc.lambda

Estionmation of the genomic control inflation statistic (lambda)
gc.em

Gene counting for haplotype analysis
g2a

Conversion of a genotype identifier to alleles
gap-package

Genetic analysis package
gap-internal

Internal functions for gap
gcontrol

genomic control
gcontrol2

genomic control based on p values
fbsize

Sample size for family-based linkage and association design
gcp

Permutation tests using GENECOUNTING
get_b_se

Get b and se from AF, n, and z
get_sdy

Get sd(y) from AF, n, b, se
get_pve_se

Get pve and its standard error from n, z
h2G

Heritability and its variance
genecounting

Gene counting for haplotype analysis
geno.recode

Genotype recoding
hap.control

Control for haplotype reconstruction
hap

Haplotype reconstruction
klem

Haplotype frequency estimation based on a genotype table of two multiallelic markers
labelManhattan

Annotate Manhattan or Miami Plot
gif

Kinship coefficient and genetic index of familiality
h2GE

Heritability and its variance when there is an environment component
hmht.control

Controls for highlights
hwe.hardy

Hardy-Weinberg equilibrium test using MCMC
hwe.jags

Hardy-Weinberg equlibrium test for a multiallelic marker using JAGS
hwe

Hardy-Weinberg equlibrium test for a multiallelic marker
hwe.cc

A likelihood ratio test of population Hardy-Weinberg equilibrium for case-control studies
mhtplot

Manhattan plot
htr

Haplotype trend regression
grid2d

Two-dimensional grid
mhtplot.trunc

Truncated Manhattan plot
h2.jags

Heritability estimation based on genomic relationship matrix using JAGS
log10pvalue

log10(p) for a P value including its scientific format
log10p

log10(p) for a normal deviate z
metap

Meta-analysis of p values
masize

Sample size calculation for mediation analysis
mr

Mendelian randomization analysis
mr_forestplot

Mendelian Randomization forest plot
mvmeta

Multivariate meta-analysis based on generalized least squares
mtdt2

Transmission/disequilibrium test of a multiallelic marker by Bradley-Terry model
muvar

Means and variances under 1- and 2- locus (biallelic) QTL model
mtdt

Transmission/disequilibrium test of a multiallelic marker
metareg

Fixed and random effects model for meta-analysis
mht.control

Controls for mhtplot
pedtodot_verbatim

Pedigree-drawing with graphviz
pedtodot

Converting pedigree(s) to dot file(s)
hap.em

Gene counting for haplotype analysis
sentinels

Sentinel identification from GWAS summary statistics
h2_mzdz

Heritability estimation according to twin correlations
pgc

Preparing weight for GENECOUNTING
plot.hap.score

Plot haplotype frequencies versus haplotype score statistics
qtlClassifier

A QTL cis/trans classifier
qtl3dplotly

3D QTL plot
qqfun

Quantile-comparison plots
qqunif

Q-Q plot for uniformly distributed random variable
runshinygap

Start shinygap
miamiplot

Miami plot
s2k

Statistics for 2 by K table
h2l

Heritability under the liability threshold model
snptest_sample

A utility to generate SNPTEST sample file
miamiplot2

Miami Plot
hap.score

Score statistics for association of traits with haplotypes
ixy

Conversion of chrosome name from strings
mhtplot2

Manhattan plot with annotations
mia

Multiple imputation analysis for hap
kin.morgan

kinship matrix for simple pedigree
inv_chr_pos_a1_a2

Retrieval of chr:pos+a1/a2 according to SNP id
invnormal

Inverse normal transformation
pbsize

Power for population-based association design
print.hap.score

Print a hap.score object
pbsize2

Power for case-control association design
logp

log(p) for a normal deviate z
makeped

A function to prepare pedigrees in post-MAKEPED format
pfc

Probability of familial clustering of disease
qtl2dplot

2D QTL plot
pfc.sim

Probability of familial clustering of disease
qtl2dplotly

2D QTL plotly
revStrand

Allele on the reverse strand
read.ms.output

A utility function to read ms output
pvalue

P value for a normal deviate
xy

Conversion of chromosome names to strings
tscc

Power calculation for two-stage case-control design
whscore

Whittemore-Halpern scores for allele-sharing