stan-dev / posterior

The posterior R package
https://mc-stan.org/posterior/
Other
167 stars 24 forks source link

`pareto_khat(..., tail="both")` returns NA if just one tail is constant #345

Closed n-kall closed 8 months ago

n-kall commented 8 months ago

One problem is that when pareto_khat(..., tail="both") sees constant tail, max(left_k, right_k) gives NA. It would probably be better to use k <- max(left_k, right_k, na.rm=TRUE)

Originally posted by @avehtari in https://github.com/stan-dev/loo/issues/250#issuecomment-1971588262