neff-deprecated {popkin}R Documentation

Calculates the effective sample size of the data

Description

Calculates the effective sample size of the data

Usage

neff(kinship, max = TRUE, w = NULL, retW = TRUE, nonneg = TRUE,
algo = c('gradient', 'newton', 'heuristic'), tol = 1e-10)

Arguments

kinship

A kinship matrix

max

Return maximum n_eff; otherwise compute n_eff using provided weights.

w

Weights for individuals.

retW

Return weights along with n_eff.

nonneg

Optimize constrained to non-negative weights.

algo

Algorithm for finding optimal non-negative weights: gradient, newton, or heuristic.

tol

Tolerance parameter for "gradient" and "newton" algorithms.

Value

A list containing n_eff and the weights.

See Also

popkin-deprecated


[Package popkin version 1.2.2 Index]