dennisprangle / gk

R package for the g-and-k distribution
GNU General Public License v2.0
5 stars 2 forks source link

Interval search bounds #2

Closed dennisprangle closed 7 years ago

dennisprangle commented 10 years ago

Explain how the interval search bounds in gk2z were derived, perhaps in a vignette.

dennisprangle commented 10 years ago

n.b. Interval search bounds go wrong for dgk(2.688,A=3,B=1,g=2,k=-0.3)

dennisprangle commented 10 years ago

I've added an old pdf document I wrote on this, but it needs revising and correction.

dennisprangle commented 10 years ago

I've used the extendInt option in uniroot. This prevents errors in most cases and means we don't need details of interval selection. However things can still go wrong e.g. dgk(-0.1,A=3,B=1,g=2,k=-0.499) I've left the pdf in the package for now in case it is useful in (1) explaining the initial choice of search interval or (2) helping with problematic cases.

dennisprangle commented 7 years ago

Fixed in v0.4.0 (first example works, second can be shown to have invalid parameters)