#### Transcript Chi-Square Practice File

8/27/2015 Quick Question to Start Our Day Briefly (2-3 sentences) describe the difference between a reductionist approach and a systems approach to biology Quantitative Skills …with a little dab of critical thinking! What are the three most important things I need to study? 1. 2. 3. Experimental Design Math • Mean, median, mode, range • SD • Rate • Chi Square • Intrinsic rate of increase • Percent error • Hardy-Weinberg • Water potential • ΔG = ΔH – TΔS Making Connections Design An Experiment Scientific Method Experimental Design • • • • • • • • • • • • Observation Hypothesis Experiment Analysis Conclusion Dependent Variable Independent Variable Constants Control Multiple Trials Correct Equipment/subjects Statistical Analysis The following statistics suggest that 16-year-olds are safer than people in their twenties, and that octogenarians are very safe. Is this true? Solution: NO! As the following graph shows, the reason 16-year-old and octogenarians appear to be safe drivers is that they don't drive nearly as much as people in other age groups. Can we conclude that United, American, and Delta are the worst airlines and Alaska, Southwest, and Continental are the best? Most complaints 2000 United Airlines 252 American Airlines 162 Delta Airlines 119 Fewest complaints 2000 Alaskan Airlines 13 South West Airlines 22 Continental Airlines 20 Solution: NO! The airlines that had the most complaints also had the most passengers. As the following graph shows, rates and percentages are often more informative than raw numbers. These two histograms have the same mean of five but they differ in their variation. Variance (s2) is the degree that that measurements deviate from the average The standard deviation, or ‘s’, for the two diagrams below are different. s=2.053 for #1 s=1.046 for #2 Histogram #1 has more deviation or variation from the mean of 5, than histogram #2 The standard deviation, s for the two diagrams below are different. s=2.053 for #1 s=1.046 for #2 which makes sense because histogram #1 has more deviation or variation from the mean of 5. Is there variation? • Where is it? – Among individuals – Among populations • What causes it? – – – – – – Snp’s Copy number variation Epigenetics Mitosis/Meiosis Sexual reproduction Etc. • How is it maintained? • How do we measure it? How do we measure variation in our data? • • • • • Mean Mode Median Variance Standard deviation Mean is the average, so… 97, 93, 90, 88, 88, 85, 83, 82, 77, 75, 74, 71, 69, 66, 59 • The mean is 1197 / 15 = 79.8 • When would this be beneficial to use? Median is the middle point, so… 97, 93, 90, 88, 88, 85, 83, 82, 77, 75, 74, 71, 69, 66, 17 • 82 is directly in the middle of the set • When would this be beneficial to use? Mode is the most used value, so… 97, 93, 90, 88, 88, 85, 83, 82, 77, 75, 74, 71, 69, 66, 59 • 88 is the most used value in the set • When would this be beneficial to use? Tutorial: Chi-Square Distribution Purpose • To measure discontinuous categorical/binned data in which a number of subjects fall into categories • We want to compare our observed data to what we expect to see. Due to chance? Due to association? • When can we use the Chi-Square Test? – Testing outcome of Mendelian Crosses, Testing Independence – Is one factor associated with another?, Testing a population for expected proportions Assumptions: • • • • • • 1 or more categories Independent observations A sample size of at least 10 Random sampling All observations must be used For the test to be accurate, the expected frequency should be at least 5 Conducting Chi-Square Analysis 1) Make a hypothesis based on your basic biological question 2) Determine the expected frequencies 3) Create a table with observed frequencies, expected frequencies, and chi-square values using the formula: (O-E)2 E 4) Find the degrees of freedom: (n-1) 5) Find the chi-square statistic in the Chi-Square Distribution table 6) If chi-square statistic > your calculated chi-square value, you do not reject your null hypothesis and vice versa. Example 1: Testing for Proportions HO: Horned lizards eat equal amounts of leaf cutter, carpenter and black ants. HA: Horned lizards eat more amounts of one species of ants than the others. Leaf Cutter Ants Carpenter Ants Black Ants Total Observed 25 18 17 60 Expected 20 20 20 60 O-E 5 -2 -3 0 (O-E)2 E 1.25 0.2 0.45 χ2 = 1.90 χ2 = Sum of all: (O-E)2 E Calculate degrees of freedom: (n-1) = 3-1 = 2 Under a critical value of your choice (e.g. α = 0.05 or 95% confidence), look up Chi-square statistic on a Chi-square distribution table. Example 1: Testing for Proportions χ2α=0.05 = 5.991 Example 1: Testing for Proportions Leaf Cutter Ants Carpenter Ants Black Ants Total Observed 25 18 17 60 Expected 20 20 20 60 O-E 5 -2 -3 0 (O-E)2 E 1.25 0.2 0.45 χ2 = 1.90 Chi-square statistic: χ2 = 5.991 Our calculated value: χ2 = 1.90 *If chi-square statistic > your calculated value, then you do not reject your null hypothesis. There is a significant difference that is not due to chance. 5.991 > 1.90 ∴ We do not reject our null hypothesis. STANDARD DEVIATION Let’s calculate a quick one! Six students took the same quiz and scored the following: 5, 6, 7, 8, 9, 10 • Find the mean • 5+6+7+8+9+10 = 45/6 = 7.5 Let’s calculate a quick one! Six students took the same quiz and scored the following: 5, 6, 7, 8, 9, 10 • Subtract the mean from each data point • 5 – 7.5 = -2.5 • 6 – 7.5 = -1.5 • 7 – 7.5 = -0.5 • 8 – 7.5 = 0.5 • 9 – 7.5 = 1.5 • 10 – 7.5 = 2.5 Let’s calculate a quick one! Six students took the same quiz and scored the following: 5, 6, 7, 8, 9, 10 • Square each one. – – – – – – 5 – 7.5 = -2.5 6 – 7.5 = -1.5 7 – 7.5 = -.5 8 – 7.5 = .5 9 – 7.5 = 1.5 10 – 7.5 = 2.5 -2.52 = 6.25 -1.52 = 2.25 -0.52 = 0.25 0.52 = 0.25 1.52 = 2.25 2.52 = 6.25 Let’s calculate a quick one! Six students took the same quiz and scored the following: 5, 6, 7, 8, 9, 10 • Sum the squares – – – – – – 5 – 7.5 = -2.5 6 – 7.5 = -1.5 7 – 7.5 = -.5 8 – 7.5 = .5 9 – 7.5 = 1.5 10 – 7.5 = 2.5 -2.52 = 6.25 -1.52 = 2.25 -0.52 = 0.25 0.52 = 0.25 1.52 = 2.25 2.52 = +6.25 17.5 Let’s calculate a quick one! Six students took the same quiz and scored the following: 5, 6, 7, 8, 9, 10 • Divide the sum of the squares by (n-1) or total number of data points – 1. – – – – – – 5 – 7.5 = -2.5 6 – 7.5 = -1.5 7 – 7.5 = -.5 8 – 7.5 = .5 9 – 7.5 = 1.5 10 – 7.5 = 2.5 -2.52 = 6.25 -1.52 = 2.25 -0.52 = 0.25 0.52 = 0.25 1.52 = 2.25 2.52 = +6.25 17.5/5 = 3.5 Let’s calculate a quick one! Six students took the same quiz and scored the following: 5, 6, 7, 8, 9, 10 • Take the square root of the this number. – – – – – – 5 – 7.5 = -2.5 6 – 7.5 = -1.5 7 – 7.5 = -.5 8 – 7.5 = .5 9 – 7.5 = 1.5 10 – 7.5 = 2.5 -2.52 = 6.25 -1.52 = 2.25 -0.52 = 0.25 0.52 = 0.25 1.52 = 2.25 2.52 = +6.25 17.5/5 = 3.5 = 1.87 Let’s calculate a quick one! Therefore if six students took the same quiz and scored the following: 5, 6, 7, 8, 9, 10 • The average of the grades was 7.5 ± 1.9 Student Hand Length Variability Number of Students 7 6 5 4 3 2 1 16 17 18 19 Hand Length (cm) 20 21 Student Hand Length Variability Number of Students 7 6 15.69 17.09 19.89 18.49 21.29 5 4 3 2 1 16 17 18 19 Hand Length (cm) 20 21 Student Hand Length Variability Number of Students 7 6 5 4 3 2 1 16 17 18 19 Hand Length (cm) 20 21 Student Hand Length Variability Number of Students 7 6 5 4 3 2 1 16 17 18 19 Hand Length (cm) 20 21 Student Hand Length Variability Number of Students 7 6 5 4 3 2 1 16 17 18 19 Hand Length (cm) 20 21 Modes of Natural Selection Quantitative Analysis YOU WILL NOT HAVE TO CALCULATE… • • • • Standard Deviation Standard Error Q10 pH However, you need to be able to understand them well enough to answer questions regarding their use in data analysis. Try this one! In Caucasian humans, hair straightness or curliness is thought to be governed by a single pair of alleles showing partial dominance. Individuals with straight hair are homozygous for the Is allele, while those with curly hair are homozygous for the Ic allele. Individuals with wavy hair are heterozygous (IsIc). In a population of 1,000 individuals, 245 were found to have straight hair, 393 had curly hair, and 362 had wavy hair. • Calculate the allelic frequencies of the Is and Ic alleles. • Explain whether or not this population is in Hardy-Weinberg equilibrium? – Justify your answer. Your explanation should include a chi-square goodness of fit test. Try this one! Two Siamese and three Persian cats survive a shipwreck and are carried on driftwood to a previously uninhabited tropical island. All five cats have normal ears, but one carries the recessive allele f or folded ears (his genotype is Ff). • Calculate the frequencies of the dominant and recessive alleles in the cat population on this island. • If you assume Hardy-Weinberg equilibrium for these alleles (admittedly very improbable), calculate the number of cats you would expect to have folded ears when the island population reaches 20,000? Big Idea 1 1. Natural selection 2. Genotypic/Phenotypic variation 3. Genetic drift/Gene flow 4. Phylogenetic tree/Cladogram 5. Adaptation 6. Allele frequency 7. Artificial selection 8. Genetic diversity/Variation 9. Biological evolution 10. Speciation Big Idea 2 1. Photosynthesis 2. Cellular respiration 3. Homeostasis 4. Changes in free energy 5. Diffusion/Osmosis/Passive/Active transport 6. Eukaryotic organelles 7. Biogeochemical cycles 8. Selectively permeable membranes 9. Feedback mechanisms 10. Biotic/Abiotic interactions 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. Mutations Meiosis/Mitosis Transcription/Translation Genotype/Phenotype DNA/RNA Processes that increase variation Genetic disorders Gene regulation Cell communication Viral genetics Big Idea 4 1. Human organ systems 2. Human organs 3. Organic molecules 4. Structure = Function 5. Community relationships 6. Ecosystem dynamics 7. Population size/growth 8. Competition/Cooperation 9. Autotrophs/Heterotrophs 10. Plant anatomy/behavior