R Dataset / Package DAAG / moths

Submitted by pmagunia on March 9, 2018 - 1:06 PM
Dataset License
GNU General Public License v2.0
Attachment Size
dataset-76376.csv 746 bytes
Documentation

Moths Data

Description

The moths data frame has 41 rows and 4 columns. These data are from a study of the effect of habitat on the densities of two species of moth (A and P). Transects were set across the search area. Within transects, sections were identified according to habitat type.

Usage

moths

Format

This data frame contains the following columns:

meters

length of transect

A

number of type A moths found

P

number of type P moths found

habitat

a factor with levels Bank, Disturbed, Lowerside, NEsoak, NWsoak, SEsoak, SWsoak, Upperside

Source

Sharyn Wragg, formerly of Australian National University

Examples

print("Quasi Poisson Regression - Example 8.3")
rbind(table(moths[,4]), sapply(split(moths[,-4], moths$habitat), apply,2,
sum))
A.glm <- glm(formula = A ~ log(meters) + factor(habitat), family =
quasipoisson, data = moths)
summary(A.glm)
  # Note the huge standard errors
moths$habitat <- relevel(moths$habitat, ref="Lowerside")
A.glm <- glm(A ~ habitat + log(meters), family=quasipoisson, data=moths)
summary(A.glm)$coef
## Consider as another possibility
A2.glm <- glm(formula = A ~ sqrt(meters) + factor(habitat), family =
                  quasipoisson(link=sqrt), data = moths)
summary(A2.glm)
--

Dataset imported from https://www.r-project.org.

Documentation License
GNU General Public License v2.0

From Around the Site...

Title Authored on Content type
R Dataset / Package car / Highway1 March 9, 2018 - 1:06 PM Dataset
R Dataset / Package Zelig / SupremeCourt March 9, 2018 - 1:06 PM Dataset
R Dataset / Package MASS / painters March 9, 2018 - 1:06 PM Dataset
R Dataset / Package Stat2Data / TMS March 9, 2018 - 1:06 PM Dataset
R Dataset / Package Ecdat / Somerville March 9, 2018 - 1:06 PM Dataset