[R] Fitting Distributions Directly From a Histogram

Spencer Graves spencer.graves at pdf.com
Mon Jun 19 02:45:56 CEST 2006


	  Won't 'interval censoring using 'survreg' in the 'survival' package 
handle this? 
(http://finzi.psych.upenn.edu/R/library/survival/html/survreg.html)

	  Hope this helps.
	  Spencer Graves

Vincent Goulet wrote:
> Le Lundi 12 Juin 2006 06:51, Lorenzo Isella a écrit :
>> Dear All,
>>
>> A simple question: packages like fitdistr should be ideal to analyze
>> samples of data taken from a univariate distribution, but what if
>> rather than the raw data of the observations you are given directly
>> and only a histogram?
> 
> Let's assume that you have not only the histogram itself, but also the breaks 
> and the counts per bin. Then you have what grouped data --- at least that's 
> how we call those in Actuarial Science. Maximum likelyhood estimation is 
> feasible for such data, but it is slightly more complicated. "Loss Models" by 
> Klugman, Panjer & Willmot (Wiley) covers this.
> 
> I'm now thinking of adding this to my actuarial science package "actuar"...
> 
>> I was thinking about generating artificially a set of data
>> corresponding to the counts binned in the histogram, but this sounds
>> too cumbersome.
>> Another question is the following: fitdistr provides the value of the
>> log-likely hood function, but what if I want e.g. a chi square test to
>> get some insight on the goodness of the fitting?
> 
> Goodness of fit tests for grouped data are also covered in Loss Models.
> 
>> I am sure there must be a way to get it straightforwardly without
>> coding it myself.
> 
> Once you have the theory, I'm afraid for now you will have to code the 
> estimation procedure yourself.
> 
> Cheers.
> 
>> Many thanks
>>
>> Lorenzo
>>
>> ______________________________________________
>> R-help at stat.math.ethz.ch mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide!
>> http://www.R-project.org/posting-guide.html
>



More information about the R-help mailing list