Skip to content

approx_conditional() can be simplified #8

@jackmwolf

Description

@jackmwolf

approx_conditional() uses an equation that can be heavily reduced to estimate the conditional variance of a phenotype.

p_s2 <- (n * means[2]^2 + (n - 1) * covs[2, 2] - a * n * means[2] -
b * (n * means[1] * means[2] + (n - 1) * covs[1, 2])) / (n - 2)

This can be reduced to:

p_s2 <- (n-1) * (covs[2, 2] - b * covs[1, 2]) / (n - 2)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions