Re: [R-sig-eco] probability distribution for zero-inflated, right skewed data

2014-06-16 Thread Johannes Björk
Definitely looks promising. Thanks Bob!

On Jun 16, 2014, at 2:29 PM, Bob O'Hara wrote:

 On 16/06/14 13:57, Johannes Björk wrote:
 Dear all,
 
 Im looking into how to fit a GLM model (Im using rjags) with data that are 
 heavily right skewed. In addition, some variables also zero-inflated. The 
 data are species area distribution measured as total area (km^2) which is 
 subsetted into area in tropical zone and area in temperate zone. The 
 last two variables contain zeros.
 
 I have google zero-inflated models... and most that come up is 
 zero-inflated negative binomial and zero-inflated negative poisson for 
 count data. I reckon I cannot use any of these distributions since my 
 variables are not discrete.
 
 Any pointer to which distribution(s) that might fit this kind of data would 
 be much appreciated.
 I think a Tweedie distribution is sometimes used, but that always makes me 
 think of escaping chickens. Recently this was published, which might also be 
 useful: 
 http://onlinelibrary.wiley.com/doi/10./2041-210X.12122/abstract. They 
 used BUGS, so you could ask them if the code is available. Even if it isn't, 
 it shouldn't be too difficult to code up.
 
 Bob
 
 -- 
 
 Bob O'Hara
 
 Biodiversity and Climate Research Centre
 Senckenberganlage 25
 D-60325 Frankfurt am Main,
 Germany
 
 Tel: +49 69 7542 1863
 Mobile: +49 1515 888 5440
 WWW:   http://www.bik-f.de/root/index.php?page_id=219
 Blog: http://blogs.nature.com/boboh
 Journal of Negative Results - EEB: www.jnr-eeb.org
 
 ___
 R-sig-ecology mailing list
 R-sig-ecology@r-project.org
 https://stat.ethz.ch/mailman/listinfo/r-sig-ecology

___
R-sig-ecology mailing list
R-sig-ecology@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-ecology


Re: [R-sig-eco] probability distribution for zero-inflated, right skewed data

2014-06-16 Thread Cade, Brian
You could try estimating the conditional cumulative distribution function
with quantile regression by estimating a large interval of quantiles (e.g.,
0.01 to 0.99 if your n is large enough).  Quantile regression will readily
handle skewed and heterogeneous responses.  Some finessing required to
check when estimates are above a mass of zeros but this is all doable.

Brian

Brian S. Cade, PhD

U. S. Geological Survey
Fort Collins Science Center
2150 Centre Ave., Bldg. C
Fort Collins, CO  80526-8818

email:  ca...@usgs.gov brian_c...@usgs.gov
tel:  970 226-9326



On Mon, Jun 16, 2014 at 5:57 AM, Johannes Björk bjork.johan...@gmail.com
wrote:

 Dear all,

 Im looking into how to fit a GLM model (Im using rjags) with data that are
 heavily right skewed. In addition, some variables also zero-inflated. The
 data are species area distribution measured as total area (km^2) which is
 subsetted into area in tropical zone and area in temperate zone. The
 last two variables contain zeros.

 I have google zero-inflated models... and most that come up is
 zero-inflated negative binomial and zero-inflated negative poisson for
 count data. I reckon I cannot use any of these distributions since my
 variables are not discrete.

 Any pointer to which distribution(s) that might fit this kind of data
 would be much appreciated.

 Attached: Histograms of the data
 ___
 R-sig-ecology mailing list
 R-sig-ecology@r-project.org
 https://stat.ethz.ch/mailman/listinfo/r-sig-ecology


[[alternative HTML version deleted]]

___
R-sig-ecology mailing list
R-sig-ecology@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-ecology


Re: [R-sig-eco] probability distribution for zero-inflated, right skewed data

2014-06-16 Thread Scott Foster

Hi,

Just a little note about computational methods for Tweedies and compound Poisson-gammas.  The package statMod has a Tweedie family that can be used in 
glm(), the package Tweedie has functions for density calculations (and other things), the package fishMod (my own package) has methods to fit Tweedie 
GLMs and compound Poisson-gamma, and lastly (but very far from leastly) mgcv has a Tweedie family too.  The mgcv fact seems to not be widely known.


None of these methods are Bayesian however.  As Bob suggested coding up a sampler should be easy enough, either from the compound representation or 
directly from the (marginal) Tweedie -- see ?rTweedie in the fishMod package or ?rtweedie in the tweedie package.


At the risk of blatant self-promotion have a look at my paper on compound Poisson-gammas -- there is a review of some of the more common methods. 
http://link.springer.com/article/10.1007/s10651-012-0233-0


Good luck!

Scott

On 16/06/14 22:29, Bob O'Hara wrote:

On 16/06/14 13:57, Johannes Björk wrote:

Dear all,

Im looking into how to fit a GLM model (Im using rjags) with data that are heavily right skewed. In addition, some variables also zero-inflated. 
The data are species area distribution measured as total area (km^2) which is subsetted into area in tropical zone and area in temperate 
zone. The last two variables contain zeros.


I have google zero-inflated models... and most that come up is zero-inflated negative binomial and zero-inflated negative poisson for count 
data. I reckon I cannot use any of these distributions since my variables are not discrete.


Any pointer to which distribution(s) that might fit this kind of data would be 
much appreciated.
I think a Tweedie distribution is sometimes used, but that always makes me think of escaping chickens. Recently this was published, which might also 
be useful: http://onlinelibrary.wiley.com/doi/10./2041-210X.12122/abstract. They used BUGS, so you could ask them if the code is available. 
Even if it isn't, it shouldn't be too difficult to code up.


Bob



--
Scott Foster
Computational Informatics
CSIRO
E scott.fos...@csiro.au T +61 3 6232 5178
Postal address: CSIRO Computational Informatics, GPO Box 1538, Hobart TAS 7001
Street Address: CSIRO Computational Informatics, Castray Esplanade, Hobart Tas 
7001, Australia
www.csiro.au

___
R-sig-ecology mailing list
R-sig-ecology@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-ecology