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

Error from NaN values #54

Open
pdeffebach opened this issue Dec 13, 2020 · 3 comments
Open

Error from NaN values #54

pdeffebach opened this issue Dec 13, 2020 · 3 comments

Comments

@pdeffebach
Copy link

Sometimes there is numerical instability leading to NaN values, and I get this error

ERROR: ArgumentError: quantiles are undefined in presence of NaNs
Stacktrace:
 [1] _quantilesort!(::Array{Float64,1}, ::Bool, ::Float64, ::Float64) at /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.5/Statistics/src/Statistics.jl:960

My understanding is that quantreg in R skips over these NaNs and prints a warning. Could QuantileRegressions do the same?

@pdeffebach
Copy link
Author

Perhaps we can just let NaN filter through? I think the error is coming from non-convergence. In which case we should just return NaN for everything

@pkofod
Copy link
Owner

pkofod commented Dec 17, 2020

Do you have a complete stacktrace? I don't know where this would happen.

@andrewmcgr
Copy link

It comes from qreg_vcov, the line:
iqre = quantile(resid, .75) - quantile(resid, .25)

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

3 participants