[Scipy-tickets] [SciPy] #1553: Improve distribution fitting

SciPy Trac scipy-tickets@scipy....
Fri Nov 4 01:53:41 CDT 2011


#1553: Improve distribution fitting
-------------------------+--------------------------------------------------
 Reporter:  pbrod        |       Owner:  somebody   
     Type:  enhancement  |      Status:  new        
 Priority:  normal       |   Milestone:  Unscheduled
Component:  scipy.stats  |     Version:  devel      
 Keywords:               |  
-------------------------+--------------------------------------------------

Comment(by pbrod):

 For the distributions that handle the out of support in the _logpdf one
 could clip the output from _logpdf in the nnlf method like this:
 {{{
      def _nnlf(self, x, *args):
         loginf = -100*log(floatinfo.machar.xmin)
         logpdf = self._logpdf(x, *args).clip(min=-loginf)
         return -sum(logpdf, axis=0)
 }}}


 To me it seems that setting a and b (see  Ticket #793) only makes things
 easy when they do not depend on the distribution parameters. If they
 depend on the parameters, there is no easy way out of the situation than
 to check for out of bounds support in the implementation specific methods.

 To me it appears cleaner if the a and b is not set if they depend on other
 parameters, but instead handled in the implementation specific methods
 _cdf, _pdf,....etc (like it is done in tukeylambda).

 Setting the b in the _argcheck method like it is done in genpareto
 distribution seems to me more like a hack.

-- 
Ticket URL: <http://projects.scipy.org/scipy/ticket/1553#comment:2>
SciPy <http://www.scipy.org>
SciPy is open-source software for mathematics, science, and engineering.


More information about the Scipy-tickets mailing list