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

Cook's distance, DFFITS, and DFBETAS always label at least one point #1

Open
mtnbikerjoshua opened this issue Mar 17, 2021 · 0 comments

Comments

@mtnbikerjoshua
Copy link
Owner

The functions jcreg_cooksd, jcreg_dffits and jcreg_dfbetas all have an argument nLabels which works fine unless nLabels = 0. If nLabels is set to zero, the functions still label one point. The problem has something to do with this line of code:

top_dff <- as.numeric(names(sort(abs(df_fits), decreasing = TRUE)[1:nLabels]))
@mtnbikerjoshua mtnbikerjoshua self-assigned this Mar 17, 2021
@mtnbikerjoshua mtnbikerjoshua removed their assignment Mar 25, 2021
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