fisherfit               package:vegan               R Documentation

_F_i_t _F_i_s_h_e_r'_s _L_o_g_s_e_r_i_e_s _a_n_d _P_r_e_s_t_o_n'_s _L_o_g_n_o_r_m_a_l _M_o_d_e_l _t_o _A_b_u_n_d_a_n_c_e _D_a_t_a

_D_e_s_c_r_i_p_t_i_o_n:

     Function 'fisherfit' fits Fisher's logseries to abundance data.
     Function 'prestonfit' groups species frequencies into doubling
     octave classes and fits Preston's lognormal model, and function
     'prestondistr' fits the truncated lognormal model without pooling
     the data into octaves.

_U_s_a_g_e:

     fisherfit(x, ...)
     ## S3 method for class 'fisherfit':
     confint(object, parm, level = 0.95, ...)
     ## S3 method for class 'fisherfit':
     profile(fitted, alpha = 0.01, maxsteps = 20, del = zmax/5, 
         ...)
     prestonfit(x, ...)
     prestondistr(x, truncate = -1, ...)
     ## S3 method for class 'prestonfit':
     plot(x, xlab = "Frequency", ylab = "Species", bar.col = "skyblue", 
         line.col = "red", lwd = 2, ...)
     ## S3 method for class 'prestonfit':
     lines(x, line.col = "red", lwd = 2, ...)
     veiledspec(x, ...)
     as.fisher(x, ...)

_A_r_g_u_m_e_n_t_s:

       x: Community data vector for fitting functions or their result
          object for 'plot' functions.

object, fitted: Fitted model.

    parm: Not used.

   level: The confidence level required.

   alpha: The extend of profiling as significance.

maxsteps: Maximum number of steps in profiling.

     del: Step length.

truncate: Truncation point for log-Normal model, in log2 units. Default
          value -1 corresponds to the left border of zero Octave. The
          choice strongly influences the fitting results.

xlab, ylab: Labels for 'x' and 'y' axes.

 bar.col: Colour of data bars.

line.col: Colour of fitted line.

     lwd: Width of fitted line.

     ...: Other parameters passed to functions. 

_D_e_t_a_i_l_s:

     In Fisher's logarithmic series the expected number of species f
     with n observed individuals is f_n = alpha x^n / n (Fisher et al.
     1943). The estimation follows Kempton & Taylor (1974) and uses
     function 'nlm'. The estimation is possible only for genuine counts
     of individuals. The parameter alpha is used as a diversity index,
     and alpha and its standard error can be estimated with a separate
     function 'fisher.alpha'. The parameter x is taken as a nuisance
     parameter which is not estimated separately but taken to be
     N/(N+alpha). Helper function 'as.fisher' transforms abundance data
     into Fisher frequency table.

     Function  'fisherfit' estimates the standard error of alpha.
     However, the confidence limits cannot be directly estimated from
     the standard error, but you should use function 'confint' based on
     profile likelihood. Function 'confint' uses function 'confint.glm'
     of the 'MASS' package, using 'profile.fisherfit' for the profile
     likelihood. Function 'profile.fisherfit' follows 'profile.glm' and
     finds the tau parameter or signed square root of two times
     log-Likelihood profile. The profile can be inspected with a 'plot'
     function which shows the tau and a dotted line corresponding to
     the Normal assumption: if standard errors can be directly used in
     Normal inference these two lines are similar.

     Preston (1948) was not satisfied with Fisher's model which seemed
     to imply infinite species richness, and postulated that rare
     species is a diminishing class and most species are in the middle
     of frequency scale. This was achieved by collapsing higher
     frequency classes into wider and wider ``octaves'' of doubling
     class limits: 1, 2, 3-4, 5-8, 9-16 etc. occurrences. Any logseries
     data will look like lognormal when plotted this way. The expected
     frequency f at abundance octave o is defined by f = S0
     exp(-(log2(o)-mu)^2/2/sigma^2), where mu is the location of the
     mode and sigma the width, both in log2 scale, and S0 is the
     expected number of species at mode. The lognormal model is usually
     truncated on the left so that some rare species are not observed.
     Function 'prestonfit' fits the truncated lognormal model as a
     second degree log-polynomial to the octave pooled data using
     Poisson error. Function 'prestondistr' fits left-truncated Normal
     distribution to log2 transformed non-pooled observations with
     direct maximization of log-likelihood. Function 'prestondistr' is
     modelled after function 'fitdistr' which can be used for
     alternative distribution models. The functions have common
     'print', 'plot' and 'lines' methods. The 'lines' function adds the
     fitted curve to the octave range with line segments showing the
     location of the mode and the width (sd) of the response.

     The total extrapolated richness from a fitted Preston model can be
     found with function 'veiledspec'. The function accepts results
     both from 'prestonfit' and from 'prestondistr'. If 'veiledspec' is
     called with a species count vector, it will internally use
     'prestonfit'. Function 'specpool' provides alternative ways of
     estimating the number of unseen species. In fact, Preston's
     lognormal model seems to be truncated at both ends, and this may
     be the main reason why its result differ from lognormal models
     fitted in Rank-Abundance diagrams with functions 'rad.lognormal'
     or 'rad.veil'.

_V_a_l_u_e:

     The function 'prestonfit' returns an object with fitted
     'coefficients', and with observed ('freq') and fitted ('fitted')
     frequencies, and a string describing the fitting 'method'.
     Function 'prestondistr' omits the entry 'fitted'. The function
     'fisherfit' returns the result of 'nlm', where item 'estimate' is
     alpha. The result object is amended with the following items: 

df.residuals: Residual degrees of freedom.

nuisance: Parameter x.

  fisher: Observed data from 'as.fisher'.

_N_o_t_e:

     It seems that Preston regarded frequencies 1, 2, 4, _etc._. as
     ``tied'' between octaves. This means that only half of the species
     with frequency 1 were shown in the lowest octave, and the rest
     were transferred to the second octave. Half of the species from
     the second octave were transferred to the higher one as well, but
     this is usually not as large number of species. This practise
     makes data look more lognormal by reducing the usually high lowest
     octaves, but is too unfair to be followed. Therefore the octaves
     used in this function include the upper limit. If you do not
     accept this, you must change the function yourself.

_A_u_t_h_o_r(_s):

     Bob O'Hara bob.ohara@helsinki.fi ('fisherfit') and Jari Oksanen.

_R_e_f_e_r_e_n_c_e_s:

     Fisher, R.A., Corbet, A.S. & Williams, C.B. (1943). The relation
     between the number of species and the number of individuals in a
     random sample of animal population. _Journal of Animal Ecology_
     12: 42-58.

     Kempton, R.A. & Taylor, L.R. (1974). Log-series and log-normal
     parameters as diversity discriminators for Lepidoptera. _Journal
     of Animal Ecology_ 43: 381-399.

     Preston, F.W. (1948) The commonness and rarity of species.
     _Ecology_ 29, 254-283.

_S_e_e _A_l_s_o:

     'diversity', 'fisher.alpha', 'radfit', 'specpool'. Function
     'fitdistr' of 'MASS' package was used as the model for
     'prestondistr'. Function 'density' can be used for smoothed
     ``non-parametric'' estimation of responses, and 'qqplot' is an
     alternative, traditional and more effective way of studying
     concordance of observed abundances to any distribution model.

_E_x_a_m_p_l_e_s:

     data(BCI)
     mod <- fisherfit(BCI[5,])
     mod
     plot(profile(mod))
     confint(mod)
     # prestonfit seems to need large samples
     mod.oct <- prestonfit(colSums(BCI))
     mod.ll <- prestondistr(colSums(BCI))
     mod.oct
     mod.ll
     plot(mod.oct)  
     lines(mod.ll, line.col="blue3") # Different
     ## Smoothed density
     den <- density(log2(colSums(BCI)))
     lines(den$x, ncol(BCI)*den$y, lwd=2) # Fairly similar to mod.oct
     ## Extrapolated richness
     veiledspec(mod.oct)
     veiledspec(mod.ll)

