Classes and methods for handling genetic data. Includes classes to represent genotypes and haplotypes at single markers up to multiple markers on multiple chromosomes. Function include allele frequencies, flagging homo/heterozygotes, flagging carriers of certain alleles, estimating and testing for Hardy-Weinberg disequilibrium, estimating and testing for linkage disequilibrium, ...
Bug fixes:
Enhancements:
Other Changes:
Add missing 'locus<-', 'gene<-', and 'marker<-' functions to NAMESPACE file.
Update Greg's email address to [email protected]
Correct 'obsolete' use of '$'. R no longer permits '$' to be used to extract named elements from vectors (just lists).
Remove the power.casectl() function, which was based on invalid assumpations. It has been marked depreciated. Please use the functions in the Bioconductor package 'GeneticsDesign' instead.
Fix bug in handling of assignment of NA value(s) to elements of an existing genotype object.
Fix warning messages from R CMD CHECK
Correct documentation error by swapping definitions of kp and alpha arguments of power.casectl().
fixes in genotypeOrder to ensure all genotype/haplotype combinations are used.
genotypeOrder<- is now exported
A note is now displayed on startup:
The R-Genetics project has developed an set of enhanced genetics packages that will shortly replace 'genetics'. Please visit the project homepage at http://rgenetics.org for more information.
binsearch() has been moved to the gtools package
New function groupGenotype to create groups/levels based on genotype names
Added some internal utility functions (.genotype2Haplotype, .genotype2Allele, and .matchGenotype)
Genotype class gets additional slot genotypeOrder (and genotype() function gets additional argument with the same name) in order to enable predefined order of genotypes in other functions e.g. summary
Added order, sort and %in% methods for genotype and haplotype classes.
Fixed genotype() with allow.partial.missing=FALSE when 'alleles' argument is passed
There is no more warning in genotype() if 'a1' or 'a2' have NA value(s) and 'alleles'' argument is specified, since NA is NA anyway
Fixed documentation of power.casectrl()
added gtools to Depends as needed by expectedGenotypes(); the latter now gives sorted genotypes according to order of given alleles
print.HWE.test() wasn't displaying the observed vs expected genotype frequency table. Fixed.
Update Greg's email address
Fixed a bug in function allele.number, as pointed out by Chris Wallace
Add R^2 to HWE and LD estimates
Correct bug in denominator of Heterozygosity calculation, as identified by Christopher Calrson
Fix handling of the 'type' and 'what' arguments for plot.genotype()
Misc bug fixes in package imports/dependencies/etc.
Add expectedGenotypes() and plot.genotypes() contributed by Gregor GORJANC
Fix bug in heterozygote when more than one allele.name is provided
Return NA and issue a warning if diseq() called on a marker with only one observed allele.
Remove debugging code that printed intermediate values (sometimes a lot of them).
Ensure that allele.freq table reported by summary.genotype has the same ordering as allele.names table.
Make it clear that the Yates continuty correction is applied only when simulate.p.value=FALSE, so that the reported test statistics for simulate.p.value=FALSE and simulate.p.value=TRUE will differ.
Attempt to fix/clarify HWE diseq. computations & synchronize documentation.
Updated to use a namespace and to work with the lastest gregmisc bundle, which was previously a package.
Add namespace support
R/diseq.R: Restore ability to show Observed vs. Expected table by adding "table" option for the 'show' parameter.
Updates to power.casectrl. (including renaming from power.casectl)
Update to work with gregmisc now that it has been converted from a package to a bundle.
Fixed Heterozygosity (H) and PIC calculations in summary.genotype. (Bug report from Gerard Tromp [email protected].
Added experimental, undocumented, and untested function hapmcmc for imputing haplotypes and related functions. (Code submitted by David Duffy [email protected]).
Fixed mislabeling of rows/columns in LDtable
Extended LDtable to resize text to fit box area, and to allow selection of which statistics are displayed, and which statistic is used for coloration.
Extended LDtable to allow all columns & rows to be shown
Added a larger example to plot.LD.data.frame documentation
Changed the name of some function parameters to be more clear and/or consistent
Added summary.LD.data.frame and print.LD.data.frame
Fixed a bug in genotype() when reorder="no", such as when called by haplotype().
New functions to estimate and test linkage disequilibrium (LD): LD, LD.genotype, LD.data.frame
New functions to display LD results print.LD, print.LD.data.frame, plot.LD.data.frame, LDtable, LDplot
Various bug-fixes and corrections
Added HWE.chisq which performs the Chi-Square test for Hardy-Wienberg Equilibrium.
Modified HWE.exact to return an object of class 'htest'.
Modified HWE.test to use HWE.exact by default for 2-allele genotypes, and HWE.chisq otherwise.
Added 'HWE.exact()', an exact test for Hardy-Wienberg Equilibrium for two alleles. Code contributed by David Duffy [email protected]
Added 'gregorius()', which computes the probability of observing all alleles with a given frequency in a sample of a specified size.