fFixEm: EM when f is fixed

Description Usage Arguments Value

Description

This function can be used for ancestry analysis when frequency matrix is fixed.

Usage

1
fFixEm(gnew, qnew, f, acc, max.iter, tol = 1e-4, pubdata)

Arguments

gnew

Genotype matrix. The number of row present in gnew is 1 and the number of column is the number of SNPs.

qnew

Initial q used in calculation. A vector. sum(q) must be 1.

f

Allele frequencies learned from the reference panels.

acc

a logical value indicating whether use quasi-Newton accelerated EM or not.

max.iter

an integer. If acc is TRUE, the number of iterations must be set. max.iter should greater than 1.

tol

Tolerance. If acc is FALSE, tol must be set. The default is 1e-4.

pubdata

You can choose a public dataset here, E11, K13, K4, K12b, K7b, World9. You also can use other public dataset which is not in this package.

Value

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


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