Calculates the effective sample size of the data
neff(kinship, max = TRUE, w = NULL, retW = TRUE, nonneg = TRUE,
algo = c('gradient', 'newton', 'heuristic'), tol = 1e-10)
A kinship matrix
Return maximum \(n_{eff}\); otherwise compute \(n_{eff}\) using provided weights.
Weights for individuals.
Return weights along with \(n_{eff}\).
Optimize constrained to non-negative weights.
Algorithm for finding optimal non-negative weights: gradient, newton, or heuristic.
Tolerance parameter for "gradient" and "newton" algorithms.
A list containing \(n_{eff}\) and the weights.