Baixe o app para aproveitar ainda mais
Prévia do material em texto
9 Correlação e regressão Ch. 9 Larson/Farber * Correlação Seção 9.1 Correlação Que tipo de relação existe entre as duas variáveis? A correlação é significante? x y Cigarros fumados por dia Nota no vestibular Altura Horas de treinamento Variável explanatória (ou independente) Variável resposta (ou dependente) Uma relação entre duas variáveis. Número de acidentes Número do sapato Altura Capacidade pulmonar Média de notas na graduação QI Correlação negativa: à medida que x cresce, y decresce. x = horas de treinamento y = número de acidentes Mapas de dispersão e tipos de correlação 60 50 40 30 20 10 0 0 2 4 6 8 10 12 14 16 18 20 Horas de treinamento Acidentes Correlação positiva: à medida que x cresce, y cresce também. x = nota no vestibular y = média de notas na graduação Média de notas na graduação Mapas de dispersão e tipos de correlação 4,00 3,75 3,50 3,00 2,75 2,50 2,25 2,00 1,50 1,75 3,25 300 350 400 450 500 550 600 650 700 750 800 Nota no vestibular Não há correlação linear. x = altura y = QI Mapas de dispersão e tipos de correlação 160 150 140 130 120 110 100 90 80 60 64 68 72 76 80 Altura QI Coeficiente de correlação r Mede a intensidade e a direção da relação linear entre duas variáveis. O intervalo de r vai de –1 a 1. Se r está próximo de 1, há uma forte correlação positiva. Se r está próximo a –1, há uma forte correlação negativa. Se r está próximo de 0, não há correlação linear. x y 8 78 2 92 5 90 12 58 15 43 9 74 6 81 Faltas Nota final Aplicação 95 90 85 80 75 70 65 60 55 45 40 50 0 2 4 6 8 10 12 14 16 Nota final X Faltas 6.084 8.464 8.100 3.364 1.849 5.476 6.561 624 184 450 696 645 666 486 57 516 3.751 579 39.898 1 8 78 2 2 92 3 5 90 4 12 58 5 15 43 6 9 74 7 6 81 64 4 25 144 225 81 36 xy x2 y2 Cálculo de r x y (3.751) (39.898) 13.030 0,975 3.155 6.084 8.464 8.100 3.364 1.849 5.476 6.561 624 184 450 696 645 666 486 57 516 3.751 579 39.898 1 8 78 2 2 92 3 5 90 4 12 58 5 15 43 6 9 74 7 6 81 64 4 25 144 225 81 36 xy x2 y2 Cálculo de r x y (3.751) (39.898) 13.030 0,975 3.155 r é o coeficiente de correlação em uma amostra. O coeficiente de correlação populacional é (rô). A distribuição amostral de r é uma distribuição t com n – 2 g.l. Estatística teste padronizada: Em um teste bicaudal de significância: Para testar a significância negativa ou positiva, no caso de cauda à esquerda e de cauda à direita: Teste de hipóteses para determinar a significância (A correlação não é significante.) (A correlação é significante.) H0 H0 H0 Ha Ha Ha Uma distribuição t com cinco graus de liberdade. ( n-2) = g.l. Tabela a18 Teste de significância Você encontrou a correlação entre o número de faltas e a nota final, r = –0,975. Há sete pares de dados. Teste a significância dessa correlação. Use = 0,01. 1. Estabeleça as hipóteses nula e alternativa. 2. Estabeleça o nível de significância. 3. Identifique a distribuição amostral. (A correlação não é significante.) (A correlação é significante.) = 0,01 Ha H0 t 0 Regiões de rejeição Valores críticos ± t0 4. Determine o valor crítico. Tabela gl = n-2 = 7-2 = 5 com α = 0,01 = 99% = 4,032 5. Determine a região de rejeição. ( grafico bicaudal α/2) 6. Determine a estatística teste. 0,975 0,975 0,975 0,975 0,09937 0,009875 9,811 , 0,049375 t 0 –4,032 –4,032 t = –9,811 cai na região de rejeição. Rejeite a hipótese nula. Há, sim, uma correlação significante entre o número de faltas e as notas finais. 7. Tome sua decisão. 8. Interprete sua decisão. Ch. 9 Larson/Farber * Regressão linear Seção 9.2 Pode-se escrever a equação de uma reta como y = mx + b, onde m é a inclinação da reta e b, o intercepto y. Assim, a reta de regressão é: A inclinação m é: E o intercepto y é: Depois de constatar que existe uma correlação linear significante, você pode escrever uma equação que descreva a relação entre as variáveis x e y. Essa equação chama-se reta de regressão ou reta do ajuste ótimo. A reta de regressão 180 190 200 210 220 230 240 250 260 1,5 2,0 2,5 3,0 Investimento em publicidade = um resíduo (xi,yi) = um ponto de dados Receita = um ponto na reta com o mesmo valor de x é um mínimo Calcule m e b. Escreva a equação da reta de regressão com x = número de faltas e y = nota final. A reta de regressão é: = –3,924x + 105,667 6.084 8.464 8.100 3.364 1.849 5.476 6.561 624 184 450 696 645 666 486 57 516 3.751 579 39.898 1 8 78 2 2 92 3 5 90 4 12 58 5 15 43 6 9 74 7 6 81 64 4 25 144 225 81 36 xy x2 y2 x y 3,924 73,714 (–3,924)(8,143) 105,667 (3.751) Xmed = 57/7 = 8,143 Ymed = 516/7 = 73,714 40 45 50 55 60 65 70 75 80 85 90 95 Faltas Nota final m = –3,924 e b = 105,667 A reta de regressão é: Note que o ponto = (8,143, 73,714) está na reta. A reta de regressão 3,924 105,667 Com a reta de regressão, é possível prever valores de y correspondentes aos valores de x que caiam em determinado intervalo de dados. A equação de regressão para o número de faltas e a nota final é: Use essa equação para prever a nota esperada de um aluno com: (a) 3 faltas (b) 12 faltas (a) (b) Prevendo valores y = –3,924(3) + 105,667 = 93,895 = –3,924(12) + 105,667 = 58,579 = –3,924x + 105,667 Ch. 9 Larson/Farber * Medidas de regressão e correlação Seção 9.3 O coeficiente de determinação, r2, é a razão entre a variação explicada em y e a variação total em y. O coeficiente de correlação entre as faltas e a nota final era r = –0,975. O coeficiente de determinação é r2 = (–0,975)2 = 0,9506. Interpretação: cerca de 95% da variação nas notas finais pode ser explicada pelo número de vezes que o aluno falta. Os outros 5% são inexplicados e podem dever-se a um erro amostral ou outras variáveis, como inteligência, tempo dedicado ao estudo etc. O coeficiente de determinação Variação explicada Variação total O coeficiente de determinação PARAMOS POR AQUI... REALIZAR LEITURA NO PLT. Medite na palavra de Deus: Em Proverbio 2 : 10;11 10 Pois quando a sabedoria entrar no teu coração, e o conhecimento for agradável à tua alma, 11 O bom siso te guardará e a inteligência te conservará. * In this chapter we will be concerned with linear correlation. (How the points fit to a straight line) In more advanced courses you may study other types of correlation. * Start with a scatter plot. It can give a picture of the relationship between the two variables. * There is no particular pattern here. * Give several examples r = -0.97, r = 0.02 and ask for the strength of the correlation. For values like 0.63 a hypothesis test is necessary to determine whether it is strong or not. * Ask students to identify the type of linear correlation described by the scatter plot. * The value or r that is computed represents the correlation coefficient of the sample. Have students interpret this result. Since r is close to -1, there is a strong negative correlation. As the number of absences increase, grades tend to decrease. Since there are 7 ordered pairs, n = 7. * The value or r that is computed represents the correlation coefficient of the sample. Have students interpret this result. Since r is close to -1, there is a strongnegative correlation. As the number of absences increase, grades tend to decrease. Since there are 7 ordered pairs, n = 7. * Another way to determine whether the correlation is significant is to compare the value of r with the values in the table. If |r| is greater than the value in the table, you can assume the correlation is significant. Notice the standardized statistic represents the difference between the hypothesized value (zero) and the test value divided by the standard error. * You loose one degree of freedom for each variable. This accounts for the n-2 degrees of freedom. Since there are 7 ordered pairs, the sampling distribution for r has 5 d.f. * Detailed calculations are shown. Depending on your calculator you can use parentheses and take fewer steps. * Remind students that the null hypothesis states the correlation coefficient is 0. To find a significant correlation you must reject the null hypothesis. * Once the correlation coefficient has been calculated, no new results need to be used to find m and b. Note that the regression line always passes through the point (x-bar, y-bar). * The value of d can be positive, negative or 0. Discuss the circumstances for each. The sum of the values of d will be 0 for the regression line. Squaring d eliminates negative values. Criteria for the Best Fit Line: The sum of the squares of the distances will be minimized. * The sums are repeated here, but they have already been calculated when determining the value of r. A TI-83 can also be used to compute the equation. * To graph the line of regression, find two points that satisfy the equation. Use any x values within the range of the data. Remember that (x-bar, y-bar) can be used as a point. For someone absent no times, a predicted grade is 105.667 (about 106). Each time a person is absent, it is expected that their grade will decrease by close to 4 points. (-3.924) * Prediction values are meaningful only for x-values in (or close t) the range f x value in the data. If x = 100 the prediction fund by using the equation would be meaningless. A person who has been absent 3 times is predicted to have a final grade of about 94. A person who has been absent 12 times is predicted to have a grade of about 59. * The proof that the coefficient of determination is equal to the square of the correlation coefficient is beyond the scope of the text. * The proof that the coefficient of determination is equal to the square of the correlation coefficient is beyond the scope of the text.
Compartilhar