gen_graph_indep {graph4lg} | R Documentation |
Create an independence graph of genetic differentiation from genetic data of class genind
Description
The function allows to create genetic graphs from genetic data by applying the conditional independence principle. Populations whose allelic frequencies covary significantly once the covariance with the other populations has been taken into account are linked on the graphs.
Usage
gen_graph_indep(
x,
dist = "basic",
cov = "sq",
pcor = "magwene",
alpha = 0.05,
test = "EED",
adj = "none",
output = "igraph"
)
Arguments
x |
An object of class |
dist |
A character string indicating the method used to compute the multilocus genetic distance between populations
|
cov |
A character string indicating the formula used to compute the covariance matrix from the distance matrix
|
pcor |
A character string indicating the way the partial correlation matrix is computed from the covariance matrix.
|
alpha |
A numeric value corresponding to the statistical tolerance threshold used to test the difference from 0 of the partial correlation coefficients. By default, 'alpha=0.05'. |
test |
A character string indicating the method used to test the significance of the partial correlation coefficients.
|
adj |
A character string indicating the way of adjusting p-values to assess the significance of the p-values
|
output |
A character string indicating the matrices included in the output list.
|
Details
The function allows to vary many parameters such as the genetic distance used, the formula used to compute the covariance, the statistical tolerance threshold, the p-values adjustment, among others.
Value
A list
of objects of class matrix
, an object of
class matrix
or a graph object of class igraph
Author(s)
P. Savary
References
Dyer RJ, Nason JD (2004). “Population graphs: the graph theoretic shape of genetic structure.” Molecular ecology, 13(7), 1713–1727. Benjamini Y, Hochberg Y (1995). “Controlling the false discovery rate: a practical and powerful approach to multiple testing.” Journal of the royal statistical society. Series B (Methodological), 289–300. Bowcock AM, Ruiz-Linares A, Tomfohrde J, Minch E, Kidd JR, Cavalli-Sforza LL (1994). “High resolution of human evolutionary trees with polymorphic microsatellites.” nature, 368(6470), 455–457. Everitt B, Hothorn T (2011). An introduction to applied multivariate analysis with R. Springer. Excoffier L, Smouse PE, Quattro JM (1992). “Analysis of molecular variance inferred from metric distances among DNA haplotypes: application to human mitochondrial DNA restriction data.” Genetics, 131(2), 479–491. Fortuna MA, Albaladejo RG, Fernández L, Aparicio A, Bascompte J (2009). “Networks of spatial genetic variation across species.” Proceedings of the National Academy of Sciences, 106(45), 19044–19049. Holm S (1979). “A simple sequentially rejective multiple test procedure.” Scandinavian journal of statistics, 65–70. Magwene PM (2001). “New tools for studying integration and modularity.” Evolution, 55(9), 1734–1745. Wermuth N, Scheidt E (1977). “Algorithm AS 105: fitting a covariance selection model to a matrix.” Journal of the Royal Statistical Society. Series C (Applied Statistics), 26(1), 88–92. Whittaker J (2009). Graphical models in applied multivariate statistics. Wiley Publishing.
Examples
data(data_ex_genind)
dist_graph_test <- gen_graph_indep(x = data_ex_genind, dist = "basic",
cov = "sq", pcor = "magwene",
alpha = 0.05, test = "EED",
adj = "none", output = "igraph")