Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Monitor the Mahalanobis norm of the mean shift #277

Open
nikohansen opened this issue Nov 14, 2024 · 1 comment
Open

Monitor the Mahalanobis norm of the mean shift #277

nikohansen opened this issue Nov 14, 2024 · 1 comment

Comments

@nikohansen
Copy link
Contributor

which should be roughly between $\sqrt n$ (on a linear function) and $\sqrt{n} / \sqrt {\mu_\text{eff}}$ (under random selection, hence we probably want to normalize by $\sqrt {\mu_\text{eff}} / \sqrt{n}$). This gives an indication how much linearity the population "sees".

@nikohansen
Copy link
Contributor Author

This would be an approximate implementation of the value, however the Mahalanobis norm should be taken before the update of the distribution parameters, because the new mean is computed with samples from the previous distribution.

def delta_mean(es):
    """return normalized delta mean"""
    n = es.mahalanobis_norm(es.mean - es.mean_old) * (
            es.sp.weights.mueff / es.N)**0.5 * es.sigma / es._sigma_old
    return n

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant