Chi-Squared Tests in Ecology. The Chi-Squared Test ( 2 ) The chi-squared test is used to study...

30
Chi-Squared Tests in Ecology

Transcript of Chi-Squared Tests in Ecology. The Chi-Squared Test ( 2 ) The chi-squared test is used to study...

Page 1: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Chi-Squared Tests in Ecology

Page 2: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

The Chi-Squared Test (2)

• The chi-squared test is used to study differences between data sets.• It is only used for frequencies (counts), never for measurements.• It is used to compare an experimental result with an expected

theoretical outcome.• It is not a valid test for small sample sizes (n<20)• It tests the validity of the null hypothesis: no difference between

groups of data.• In ecology, chi-squared tests are used to study habitat preference.

Page 3: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Mangrove (Avicennia marina var. resinifera)

Page 4: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Mangroves are doing well in USA these days…

Page 5: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Mangrove forests vs shrimp farming

Page 6: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Pneumatophores

• Some plants have aerial roots – pneumatophores• These can come in handy in waterlogged soil where oxygen levels are

very low…

Page 7: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Soil porosity is related to the average size of soil particles…• Larger particles, like sand, have larger spaces for air• Clay soils have very tiny particles, much smaller spaces for air

Page 8: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Experimental Design• 1 m x 1 m quadrats were placed

around many mangroves in numerous locations.• Pneumatophores were counted.• Chi-squared test was use to

compare observed results for pneumatophore density.• Null hypothesis: no difference in

density between substrates (soils)

Page 9: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.
Page 10: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.
Page 11: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.
Page 12: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.
Page 13: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.
Page 14: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

The Flat Periwinkle(Littorina littoralis)

Page 15: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Periwinkles feed on a number of seaweed species

Page 16: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Food preference is a form of animal behavior• Using quadrats, the

number of periwinkles associated with each seaweed species was recorded.

Page 17: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

State your null hypothesis for this investigation (H0)

• H0: There is no difference between the numbers of periwinkles associated with different species.

• What is the alternative hypothesis (HA)?

• HA : There is a real difference between numbers of periwinkles associated with different species.

Page 18: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Use the chi-squared test to determine if the observed differences are significant or if they can be attributed to chance alone.

Enter the observed values and calculate the chi-squared value

Page 19: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Here’s how you do it…

• The expected value (E) would be the mean number of periwinkles associated with the four seaweed species.

Page 20: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Now Complete the Chart…

•Calculate the degrees of freedom: •4-1 = 3

Page 21: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Check your Chi-square table for 3 degrees of freedom.

• 57.4 >> 7.82, 11.34• Is H0 accepted or rejected?• There is a significant difference in feeding preferences of periwinkles.

Page 22: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Woodlice (Pillbugs) Experiment

Page 23: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.
Page 24: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Category O E O-E (O-E)2 (O-E)2/EDry 15 25 -10 100 4

Humid 35 25 +10 100 4

Chi-squared value is 8 for 1DF

Page 25: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Chi-Square Homework Worksheet

• A marketing analyst wishes to see whether consumers have any preference among five flavors of a new fruit candy.

• A random sample of 100 people provided the following data.

Flavor Preference

Cherry 32

Strawberry 28

Orange 16

Lime 14

Grape 10

Page 26: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

What is the null hypothesis?

• How do you calculate your expected value? • How many degrees of freedom do you have?

• Show your chi-square calculations below, and state whether the null hypothesis is accepted or rejected.

Page 27: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Flavor Preference

Cherry 32

Strawberry 28

Orange 16

Lime 14

Grape 10

Page 28: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

A science teacher living in the desert noticed that native mesquite trees differed in terms of number of parasitic mistletoe plants they contained. Mesquite trees in residential neighborhoods tended to have fewer parasitic plants than trees found in undisturbed areas.

• RESEARCH QUESTION: Is there really more mistletoe in the undisturbed areas than in his neighborhood?• What is his hypothesis?

Page 29: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Mesquite and Mistletoe

Page 30: Chi-Squared Tests in Ecology. The Chi-Squared Test (  2 ) The chi-squared test is used to study differences between data sets. It is only used for frequencies.

Tree #

“wild” trees

Residential trees

1 26 62 11 83 16 14 9 05 3 06 14 07 5 38 8 39 14 310 15 1

Here is his data. Calculate the chi-squared value for the null hypothesis.