qn: quasi-Newton algorithm for ancestry analysis

Description Usage Arguments Value Examples

Description

Use quasi-Newton algorithm to accelerate EM or block relaxation.

Usage

1
qn(g, q, f, tol = 1e-4, method, model)

Arguments

g

Genotype matrix with dimensions n × p, where n is sample size and p is the number of SNPs.

q

Ancestry coefficient matrix with dimensions n × K, where n is sample size and K is the number of populations.

f

Minor allele frequency matrix with dimensions K × p, where K is the number of populations and p is the number of SNPs.

tol

Tolerance, the default value is 1e-4.

method

Choose which algorithm you want to use. EM or BR.

model

Choose which model you want to use. Supervised learning or unsupervised learning.

Value

Estimation results of q, f and the loglikelihood value of each iteration.

Examples

1
## qn(g, q, f, tol = 1e-4, method = 'BR', model = 'supervised')

radmixture documentation built on May 2, 2019, 6:11 a.m.