Bölüm m 4: Normallik Varsayımı:Klasik Normal Dogrusal Regresyo Modeli Eğer amacımız sadece okta tahmii yapmak olsaydı SEK yeterli sayılabilirdi. Amac sadece β 2 (^) yi elde etmek degıl, ou kullaarak birseyler söyleyebilme ya da gerçek β 2 ye ilişki çıkarsamalar yapmaya da yöeliktir. SEK yötemi ui i olasılık özelliğie ilişki bir varsayımda bulumadığı içi ÖRF de ARF içi çıkarsamalar yapmada SEK bir işe yaramaz. Şayet u i ler belli bir olasılık dagılıma uydugu varsayarsak bu boşluk dolar 2..Normallik Varsayımı Klasik ormal doğrusal regresyo modeli her bir ui i aşağıdaki değerlerle ormal dağılgığıı varsayar: Ortalama: E(ui) = 0 Varyas: E(ui) = σ² orv(ui,uj): E(ui,uj) = 0 i j u i ~ N(0, σ²) burada ~ biçimide dağılmıştır alamıa gelir; N ise ormal dağılımı temsil eder; paratez içidekiler ortalamayla varyası göstermektedir.
Cetral Limit Theorem As Sample Size Gets Large Eough Samplig Distributio Becomes Almost Normal regardless of shape of populatio X 2
Cetral Limit Theorem Asymptotic Normality implies that P(Z<z) Φ(z) (z) as,, or P(Z<z) Φ(z) The cetral limit theorem states that the stadardized average of ay populatio with mea µ ad variace σ 2 is asymptotically ~N(0,), or Z = Y µ Y a ~ N ( 0, ) σ 3
Properties of the Normal If X~N(µ,σ 2 ), the ax+b ~N(aµ+b,a 2 σ 2 ) A liear combiatio of idepedet, idetically distributed (iid( iid) ) ormal radom variables will also be ormally distributed If Y,Y 2, Y are iid ad ~N(µ,σ 2 ), the Y ~ N µ, σ 2 4
Whe the Populatio is Normal Cetral Tedecy σ µ _ µ x = Variatio _ σ x = Samplig with Replacemet Populatio Distributio σ = 0 µ = 50 X Samplig Distributios = 4 σ X = 5 =6 σ X = 2.5 µ X - = 50 X 5
Normal dağı ğılmış iki değişkei sıfır s r ortak varyası ya da korelasyou iki değişkei bağı ğımsız z oldukları alamıa a gelir. O halde şöyle yazabiliriz. orv(ui,uj):0 E(ui,uj) = 0 i j ui ~ NBD(0,σ²) Normallik varsayımıı edeleri Merkezi Limit Teoremi,çok ok sayıda bağı ğımsız z ve ayı biçimde imde dağı ğılmış rassal değişkeler varsa, bu değişkeleri sayısı sosuza doğru arttıkça, a, buları toplam dağı ğılımıı,birkaç aykırılık k dışıd ışıda,ormal dağı ğılıma yaklaştığı gösterilebilir. Merkezi limit teoremii bir başka biçimi, imi, değişke sayısı çok büyük k olmasa ya da bu değişkeler tam bağı ğımsız z dağı ğılsalarda toplamlarıı yie de ormal dağı ğılabileceğii ii ileri sürer. s Normal dağı ğılımı bir özelliğide, ide, ormal dağı ğılmış değişkeleri doğrusal foksiyouu da ormal dağı ğılmış olmasıdır. Normal dağı ğılım m yalızca iki katsayı içerdiğide ide göreli g olarak basit bir dağı ğılımdır. 6
Normallik Varsayımı SEK tahmi edicileri özellikleri Sapmasızd zdırlar. E küçük üçük k varyaslıdırlar rlar Tutarlıdırlar.Yai rlar.yai öreklem sosuza doğru büyürke b tahmi ediciler gerçek ek değerlerie erlerie doğru yakısalar. β şu u değerlerle erlerle ormal dağı ğılır: Ortalama : E(β (^) ) = β Xi 2 Var(β ) : σ² B (^) = σ 2 x 2 i β 2 şu u değerlerle erlerle ormal dağı ğılır: Ortalama : E(β2(^)) = β2 Var (β2)( : σ 2 = x 2 (-2) 2)σ 2 (^) / σ²,, -2 2 serbestlik derecesi X 2 (ki-kare) kare) dağı ğılımıa uyar. (β (^),β 2 (^)), σ 2 (^) de bağı ğımsız z olarak dağı ğılırlar. β (^) ve β 2 (^), doğrusal olsu olması bütü b sapmasız z tahmi ediciler içide i ide e düşük k varyaslı olalarıdır. r. E küçük üçük k kareler tahmi edicileri E iyi sapmasız tahmi edicileridir σ 2 7
u i i 0 ortalama,σ 2 varyasla ormal dağı ğıldığıı varsayarsak, Yi i kedisi de aşağıa ğıdaki ortalama ve varyasla ormal dağı ğılır r : E(Yi) = β + β2xi var(yi) = σ2 EYO(E Yüksek Y Olabilirlik) Tahmi yötemy temide ayı β regresyo katsayılar larıı verir. σ 2 i EYO tahmi edicisi u 2 ı / dir. Bu tahmi edici sapmalıdır ama σ 2 i SEK tahmi edicisi u 2 i /(-2),g 2),görüldüğü gibi sapmasızd zdır. Öyleyse sosuza doğru büyüdükçe b σ 2 i EYO tahmi edicisi de sapmasız olur. 8
Teorem 4... Z,Z2,...,Z değişkeleri, Zi ~ N( µ,σ2) dağı ğılımıa uya ormal ve bağı ğımsız z dağı ğılmış değişkelerse, Z = kizi toplamı da, ortalaması kiµi, i, varyası ki2σi2 ola Zi ~N ( kiµi, i, ki2σi2 ) dağı ğılımıa göre g ormal dağı ğılmıştır.buradaki ki ler hepsi sıfır s r olmaya sabitler,µ ortalama değerlerdir. erlerdir. Teorem 4.2. Z,Z2,...,Z değişkeleri ormal dağı ğılmış ama bağı ğımsız z değilse, Z= kizi toplamı da, ortalaması kiµi i, varyası [ k i 2σ 2 i + 2 k2 i k j orv(zi,zj), i j] i ola bir ormal dağı ğılıma uygu dağı ğılır. Teorem 4.3. Z,Z2,...,Z değişkeleri, Zi ~ N(0,) stadart ormal dağı ğılımıa uya ormal ve bağı ğımsız dağı ğılmış değişkelerse, Zi2 = Z 2 +Z 22 +... +Z2 toplamıda, sd si si ola ki-kare kare dağı ğılımıa uyar.simgelerle, Zi2 ~ X2. Burada serbestlik derecesii (sd) gösterir. g 9
The Chi-Square Distributio Suppose that Z i, i=,,, are iid ~ N(0,), ad X= (Z 2 i ), the X has a chi-square distributio with degrees of freedom (df( df), that is X~χ 2 If X~χ 2,, the E(X)= ad Var(X)=2 Teorem 4.4. Z,Z2,...,Z değişkeleri, herbirii sd si si ola ki-kare kare dağı ğılımlarıa uya bağı ğımsız z dağı ğılmış rassal değişkelerse, buları toplamı ola Zi = Z + Z2 +...+ Z de, sd si si k = ki ola bir ki-kare kare dağı ğılımıa uyar. 0
The t distributio If a radom variable, T, has a t distributio with degrees of freedom, the it is deoted as T~t E(T)=0 (for >) ad Var(T)=/( )=/(-2) (for >2) T is a fuctio of Z~N(0,) ad X~χ 2 as follows: T = Z X
Teorem 4.5 Zi stadart ormal değişke [Zi ~ N (0,) ] ike Z2 de k sd li ki-kare kare dağı ğılımıa uyuyorsa ve Z2 de bağı ğımsızsa, o zama, Z2 Z stadart ormal değişke t = = = ----- ~ t k Z2 / k Z2 bağı ğımsız z ki-kare kare değişkei / sd Teorem 4.6 Z ile Z2, sd leri sırass rasıyla k, k2 ola bağı ğımsız z dağı ğılmış ki-kare kare değişkeleriyseler Z / k F = ~ Fk,k2 burada k= payı sd, k2= paydaı sd. Z2 / k2 Teorem 4.7 sd si si k ola (studet) t değişkeii karesi, payı sd si si k=, paydaı sd si si k2 = k ola bir F dağı ğılımıdır. Yai, F,k = t 2 k Normallik varsayımıı dayadığı kurumsal temel Merkezi Limit Teoremidir. 2
The F Distributio If a radom variable, F, has a F distributio with (k,k 2 ) df,, the it is deoted as F~F k,k2 F is a fuctio of X ~χ 2 k ad X 2 ~χ 2 k2 as follows: F = X X 2 k k 2 3
What Make a Good Estimator? Ubiasedess Efficiecy Mea Square Error (MSE) Asymptotic properties (for large samples): Cosistecy 4
Properties of the Mea Ubiasedess Mea of samplig distributio equals populatio mea Efficiecy Sample mea comes closer to populatio mea tha ay other ubiased estimator Cosistecy As sample size icreases,, variatio of sample mea from populatio mea decreases 5
Ubiasedess of Estimator Wat your estimator to be right, o average We say a estimator, W, of a Populatio Parameter, θ,, is ubiased if E(W)=E(θ) For our example, that meas we wat E ( Y ) = µ Y 6
Ubiasedess P(X) Ubiased Biased µ X 7
8 Proof: Sample Mea is Ubiased Proof: Sample Mea is Ubiased Y Y i Y i i i i Y E Y E Y E µ µ µ = = = = = = = = ) ( ) (
Efficiecy P(X) Samplig Distributio of Media Samplig Distributio of Mea µ X 9
Efficiecy of Estimator Wat your estimator to be closer to the truth, o average, tha ay other estimator We say a estimator, W, is efficiet if Var(W)< Var(ay other estimator) Note, for our example Var( Y ) 2 = Var Yi = σ = 2 i= i= σ 2 20
Cosistecy of Estimator Asymptotic properties, that is, what happes as the sample size goes to ifiity? Wat distributio of W to coverge to θ,, i.e. plim(w)= )=θ For our example, that meas we wat ( ) Y µ > ε 0as P Y 2
Cosistecy P(X) Smaller sample size A B Larger sample size µ X 22
More o Cosistecy A ubiased estimator is ot ecessarily cosistet suppose choose Y as estimate of µ Y, sice E(Y )= µ Y, the plim(y ) µ Y A ubiased estimator, W, is cosistet if Var(W) 0 as Law of Large Numbers refers to the cosistecy of sample average as estimator for µ,, that is, to the fact that: plim( Y) = µ Y 23
Ifereces about the Slope: t Test t Test for a Populatio Slope Is a Liear Relatioship Betwee X & Y? Null ad Alterative Hypotheses H 0 : β = 0 (No Liear Relatioship) H : β 0 (Liear Relatioship) Test Statistic: t = b S b β ad df = - 2 Where S b = ( i = S X YX i X ) 2 24
Example: Produce Stores Data for 7 Stores: Aual Store Square Feet Sales ($000),726 3,68 2,542 3,395 3 2,86 6,653 4 5,555 9,543 5,292 3,38 6 2,208 5,563 7,33 3,760 Regressio Model Obtaied: Y i = 636.45 +.487X i The slope of this model is.487. Is there a liear relatioship betwee the square footage of a store ad its aual sales? 25
Ifereces about the Slope: t Test Example H 0 : β = 0 H : β 0 α =.05 df = 7-2 = 7 Critical Value(s): Test Statistic: From Excel Pritout t Stat P-value Itercept 3.6244333 0.05488 X Variable 9.009944 0.000282 Decisio: Reject.025-2.5706 Reject.025 0 2.5706 t Reject H 0 Coclusio: There is evidece of a relatioship. 26
Ifereces about the Slope: Cofidece Iterval Example Cofidece Iterval Estimate of the Slope b ± t -2 S b Excel Pritout for Produce Stores Lower 95% Upper 95% Itercept 475.80926 2797.0853 X Variable.06249037.9077694 At 95% level of Cofidece The cofidece Iterval for the slope is (.062,.9). Does ot iclude 0. Coclusio: There is a sigificat liear relatioship betwee aual sales ad the size of the store. 27
Estimatio of Predicted Values Cofidece Iterval Estimate for µ XY The Mea of Y give a particular X i Stadard error of the estimate Ŷ i ± t t value from table with df=-2 2 Syx Size of iterval vary accordig to distace away from mea, X. + ( i = X ( i X i X ) 2 X ) 2 28
Estimatio of Predicted Values Cofidece Iterval Estimate for Idividual Respose Y i at a Particular X i Additio of this icreased width of iterval from that for the mea Y Ŷ i ± t 2 Syx + + ( X i = ( i X i X ) 2 X ) 2 29
Iterval Estimates for Differet Values of X Y Cofidece Iterval for a idividual Y i Cofidece Iterval for the mea of Y Y i = b 0 + b X i _ X A Give X X 30
Example: Produce Stores Data for 7 Stores: Aual Store Square Feet Sales ($000),726 3,68 2,542 3,395 3 2,86 6,653 4 5,555 9,543 5,292 3,38 6 2,208 5,563 7,33 3,760 Predict the aual sales for a store with 2000 square feet. Regressio Model Obtaied: Y i = 636.45 +.487X i 3
Estimatio of Predicted Values: Example Cofidece Iterval Estimate for Idividual Y Fid the 95% cofidece iterval for the average aual sales for stores of 2,000 square feet Predicted Sales Y i = 636.45 +.487X i = 460.45 ($000) X = 2350.29 S YX = 6.75 t -2 = t 5 = 2.5706 Ŷ i ± t 2 Syx + ( X i = i ( X i X ) 2 X ) 2 = 460.45 ± 980.97 Cofidece iterval for mea Y 32
Estimatio of Predicted Values: Example Cofidece Iterval Estimate for µ XY Fid the 95% cofidece iterval for aual sales of oe particular stores of 2,000 square feet Predicted Sales Y i = 636.45 +.487X i = 460.45 ($000) X = 2350.29 S YX = 6.75 t -2 = t 5 = 2.5706 Ŷ i ± t 2 Syx + + ( X i = i ( X i X ) 2 X ) 2 = 460.45 ± 853.45 Cofidece iterval for idividual 33 Y
Radom Samples ad Samplig For a radom variable Y, repeated draws from the same populatio ca be labeled as Y, Y 2,..., Y If every combiatio of sample poits has a equal chace of beig selected, this is a radom sample A radom sample is a set of idepedet, idetically distributed (i.i.d) radom variables 34
Estimators ad Estimates Typically, we ca t t observe the full populatio, so we must make ifereces base o estimates from a radom sample A estimator is just a mathematical formula for estimatig a populatio parameter from sample data A estimate is the actual umber the formula produces from the sample data 35
Examples of Estimators Suppose we wat to estimate the populatio mea Suppose we use the formula for E(Y), but substitute / for f(y i ) as the probability weight sice each poit has a equal chace of beig icluded i the sample, the Ca calculate the sample average for our sample: Y = i= Y i 36
Estimate of Populatio Variace We have a good estimate of µ Y, would like a good estimate of σ 2 Y Ca use the sample variace give below ote divisio by -, ot, sice mea is estimated too if kow µ ca use S 2 = i= ( ) 2 Y Y i 37
Estimators as Radom Variables Each of our sample statistics (e.g. the sample mea, sample variace, etc.) is a radom variable - Why? Each time we pull a radom sample, we ll get differet sample statistics If we pull lots ad lots of samples, we ll get a distributio of sample statistics 38
Correlatio: Measurig the Stregth of Associatio Aswer How Strog Is the Liear Relatioship Betwee 2 Variables? Coefficiet of Correlatio Used Populatio correlatio coefficiet deoted ρ ( Rho ) Values rage from - to + Measures degree of associatio Is the Square Root of the Coefficiet of Determiatio 39
Test of Coefficiet of Correlatio Tests If There Is a Liear Relatioship Betwee 2 Numerical Variables Same Coclusio as Testig Populatio Slope β Hypotheses H 0 : ρ = 0 (No Correlatio) H : ρ 0 (Correlatio) 40