markvanderloo/extremevalues

Nan value

Opened this issue · 2 comments

Hello I have a question.
when I use extremevalues package, it show me "NaN create" message.
How to solve this?

sample code
y <- rlnorm(100)
y <- c(0.1min(y),y,10max(y))
K <- getOutliers(y,method="I",distribution="lognormal")
L <- getOutliers(y,method="II",distribution="lognormal")
par(mfrow=c(1,2))
outlierPlot(y,K,mode="qq")
outlierPlot(y,L,mode="residual")

I reference above code and then use my data. (change y value to my data(numeric))
But it is not work properly.

error code sample >>> ex) outlierPlot(y,K,mode="qq")
Error in while (par$residuals[i - 1] > par$limit[2] & i > tail(iLambda, :
missing value where TRUE/FALSE needed
In addition: Warning message:
In qlnorm(p, par$mu, par$sigma) : NaN was created.

It is hard to trace this issue if I can't reproduce it.

Could you be so kind to create a small reproducible example that replicates the warning message you get? That is, please provide a small y vector that gives this error.

Thank you for answer ! I just want to find outlier value using this packages.
If you have a time, please confirm my issue. thank you!

  • test code :

K <- getOutliers(test$char_level,method="I",distribution="lognormal")
L <- getOutliers(test$char_level,method="II",distribution="lognormal")
Error in while (par$residuals[i - 1] > par$limit[2] & i > tail(iLambda, :
missing value where TRUE/FALSE needed
In addition: Warning message:
In qlnorm(p, par$mu, par$sigma) : NaN이 생성되었습니다
par(mfrow=c(1,2))
outlierPlot(y,K,mode="qq")
outlierPlot(y,L,mode="residual")