satisfies_nonzerof4: Test f4 constraints on a graph

satisfies_nonzerof4R Documentation

Test f4 constraints on a graph

Description

This function returns TRUE if and only if the admixture graph is compatible with the f4-statistics listed in nonzero_f4 being non-zero

Usage

satisfies_nonzerof4(graph, nonzero_f4)

Arguments

graph

An admixture graph

nonzero_f4

A data frame or matrix with four columns. One row for each f4-statistic which is expected to be non-zero

Value

TRUE if all constraints are satisfied, else FALSE

Examples

## Not run: 
# Test whether f4(A,B; C,D) is expected to be non-zero in this graph:
nonzero_f4 = matrix(c('A', 'B', 'C', 'D'), 1)
satisfies_nonzerof4(random_admixturegraph(5, 2), nonzero_f4)

## End(Not run)

uqrmaie1/admixtools documentation built on Nov. 3, 2024, 12:56 a.m.