Computation of inbreeding coefficient
HWf
computes the inbreeding coefficient for sample
of genotype counts, or a matrix of genotype counts.
HWf(X)
X |
a vector or matrix of genotype counts (AA, AB, BB) |
For monomorphic markers a warning is issued, and the estimate for the inbreeding coefficient is NaN.
Returns a single inbreeding coefficient (intraclass correlation coefficient), if X
is a single sample, or a vector of inbreeding coefficients, if X
is a matrix with genotype counts.
Jan Graffelman jan.graffelman@upc.edu
Crow, J. F. and Kimura, M. (1970) An introduction to population genetics theory. Harper \& Row, publishers, New York
# # A single sample # x <- c(MM=298,MN=489,NN=213) fhat <- HWf(x) cat("Inbreeding coefficient: ",fhat,"\n") # # Multiple samples # X <- HWData(nm=100,n=1000) fhat <- HWf(X)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.