Algebra Review De Ning Review Of Linear Algebra For Statistics

2y ago
88 Views
20 Downloads
242.71 KB
35 Pages
Last View : 22d ago
Last Download : 3m ago
Upload by : Aydin Oneil
Transcription

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsReview of Linear Algebra for StatisticsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesBrian Vegetabile2017 Statistics BootcampDepartment of StatisticsUniversity of California, IrvineSimple LinearRegressionReferencesSeptember 22nd, 20161 / 35

06 - LinearAlgebraReviewOverview IDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatrices We wrap up the math topics by reviewing some linearalgebra concepts Linear algebra will become an important tool for you as astatisticianOperations ofMatrices You’ll be using matrix operations most of the year, butSimple LinearRegressionthe main necessity for linear algebra will come in STAT200C.References2 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesOverview II Here are a few good references for reviewingundergraduate linear algebra in general Introduction to Linear Algebra by Gilbert Strang Gilbert Strang’s Lectures on YouTube(https://www.youtube.com/watch?v ZK3O402wf1c) Linear Algebra and it’s Applications by David Lay Linear Algebra by Friedberg, Insel, Spence (Upper divisiontext) Graduate Level Linear Algebra References for Statistics Matrix Algebra from a Statisticians Perspective by DavidHarville Appendix of Linear Regression Analysis by George Seberand Alan Lee Appendix of Applied Linear Regression by SanfordWeisberg3 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesMotivation I A familiarity with matrices will allow you to expand thetypes of statistics you can do. Consider the multivariate normal distributionX (X1 , X2 , . . . , Xn )T 1T 1f (x) pexp (x µ) Σ (x µ)2(2π)n Σ 1which is said to be “non-degenerate” when Σ ispositive-definite. Additionally, x is a real-valued n-dimensional columnvector and Σ is the determinant of Σ To investigate many of the properties of this distributionwe’ll need matrix algebra4 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMotivation II We’ll specifically use this distribution to explore linearregression Let Y be a random variable which has some mean µwhich we measure under error , , specificallyMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionY µ We will focus on linear models whereµ β0 β1 x1 · · · βp 1 xp 1Referenceswhere x are explanatory variables and each βj is unknownand to be estimated5 / 35

06 - LinearAlgebraReviewMotivation III If we consider a random sample of n observations we willDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionhave Y1 Y2 . .Yn x10x20.x11x21.x1,p 1x2,p 1.xn0 xn1 . . .xn,p 1 β0β1. 1 2. nβp 1 Or more simply writtenY Xβ References We will eventually show that Y Nn (Xβ, Σ). Matrix algebra will play a very important role throughoutunderstanding linear algebra6 / 35

06 - LinearAlgebraReviewDefining a MatrixDefiningMatricesBasic MatrixOperations A rectangular array of real numbers is called a matrix. Special Typesof Matrices MatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesa11a21.a12a22.a1na2n.am1 am2 . . .amn A matrix with m rows and n columns is referred to as anm n matrix Matrices will often be denoted by boldface letters X. Additionally we can denote a matrix X {aij }7 / 35

06 - LinearAlgebraReviewBasic Matrix Operations IDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferences Scalar Multiplication: Consider a matrix A and a scalar k,thenkA k{aij } {kaij } Matrix Addition: Consider two matrices A and B, if theyare both of dimension m n then we define additionbetween these two matrices. Specifically A B is them n matrix {aij bij } for all pairs i, j. Matrix addition is commutative and associative Additionally matrices having the same number of rows andcolumns are said to be conformal for addition (orsubtraction).8 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesBasic Matrix Operations II Matrix Multiplication: Let A {aij } represent an m nmatrix and B {bij } a p q matrix. When n p (whenA has the same number of columns as B has rows), thenthe matrix product AB is defined to be the m q matrixwhose ij th element isnXaik bkj ai1 b1j ai2 b2j · · · ain bnjk 1 The formation AB is called the premultiplication of B byA or the postmultiplication of A by B. When n 6 p then the matrix product AB is undefined. Two n n matrices A and B are said to commute ifAB BA9 / 35

06 - LinearAlgebraReviewBasic Matrix Operations IIIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatrices Matrix Transpose: The transpose of an m n matrix A,to be denoted AT or A0 is the n m matrix whose ij thelement is the jith element of A. For any matrix A, (A0 )0 A For any two matrices A and B which are conformal foraddition(A B)0 A0 B0Operations ofMatricesSimple LinearRegressionReferences Finally any two matrices A and B for which the productis defined,(AB)0 B0 A010 / 35

06 - LinearAlgebraReviewDefiningMatricesVectors A matrix with only one columnBasic MatrixOperations Special Typesof Matrices MatrixInversionSimple LinearRegressionReferences amProperties ofMatricesOperations ofMatricesa1a2.is called an m-dimensional column vector A matrix with only one row is called a row vector Vectors will often be denoted by lower case bold symbolsx. Clearly the transpose of an m-dimensional column vectoris an m-dimensional row vector11 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionSquare Matrices One of the most important types of matrices in all ofstatistics is the square matrix A matrix having the same number of rows as it doescolumns is called a square matrix An n n square matrix is said to have order n.Properties ofMatrices Operations ofMatrices Simple LinearRegressionReferencesa11a21.a12a22.a1na2n.an1 an2 . . .ann The set of terms {aii } are called the diagonal elements ofthe square matrix and the terms {aii }, i 6 j are theoff-diagonal terms12 / 35

06 - LinearAlgebraReviewSymmetric MatricesDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegression A matrix A is said to be symmetric is A0 A Thus a symmetric matrix is a square matrix where theij th element equals the jith element. 540 4 10 2 0 23References13 / 35

06 - LinearAlgebraReviewDiagonal MatrixDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferences A diagonal matrix is a square matrix whose off-diagonalelements are zero, that is d1 0 . . . 0 d2 . . . . . . .0 0 .00. dn The effect of premultiplying an m n matrix A by am m diagonal matrix D, DA is to multiply eachelement of the ith row of A by the element dii .14 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesIdentity Matrix Often the most useful diagonal matrix is the identitymatrix In where the subscript n denotes the dimension ofthe identity matrix (n n). That is, 1 0 . 0 0 1 . 0 In . . . . . . . 0 0 .1often the subscript n is dropped. An important property isIA AI A15 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionMatrix Inversion I For any scalar c there is a number called the inverse of c,say d such that the product of cd 1. For example, ifc 3, then d 1/c 1/3, and the inverseof 3 is 1/3. This can be extended to square matricesProperties ofMatricesDefinition (Matrix Inverse)Operations ofMatricesAn n n square matrix A is called invertible (also nonsingularand non-degenerate) if there exists an n n square matrix Bsuch thatAB BA InSimple LinearRegressionReferencesIf this is the case, then the matrix B is uniquely determined byA and is called the inverse of A denoted A 116 / 35

06 - LinearAlgebraReviewMatrix Inversion IIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatrices The collection of matrices that have an inverse are calledfull rank, invertible, or nonsingular. A square matrix that is not invertible, is of less than fullrank or singular. The identity matrix is its own inverse (In ) 1 In .Simple LinearRegressionReferences17 / 35

06 - LinearAlgebraReviewDefiningMatricesInverting a 2 2 Matrix. I Consider the following matrixBasic MatrixOperations Special Typesof MatricesMatrixInversionProperties ofMatricesA the inverse of A denoted A 1 isOperations ofMatricesASimple LinearRegressionReferencesa11 a12a21 a22 11 A a22 a12 a21 a11 where the determinant of A, A a11 a22 a12 a21 By our previous definitions we should have thatAA 1 I18 / 35

06 - LinearAlgebraReviewInverting a 2 2 Matrix. IIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesAA 1 1a11 a12a22 a12 a21 a22 a21 a11a11 a22 a12 a21 1a11 a22 a12 a21 a11 a12 a12 a aa aa aa11 a22 a12 a2121 2222 2121 a12 a22 1 0 0 1 This satisfies our requirement19 / 35

06 - LinearAlgebraReviewDefiningMatricesOrthogonality Two vectors a and b (of the same length), are orthogonalifa0 b 0Basic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatrices An r c matrix Q has orthonormal columns if itscolumns, viewed as a set c r different r 1 vectors, areorthogonal and in addition have length 1. This is equivalent toOperations ofMatricesQ0 Q ISimple LinearRegressionReferences Additionally a square matrix A is orthogonal ifA0 A AA0 Iso A 1 A0 .20 / 35

06 - LinearAlgebraReviewLinear Dependence and Rank IDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferences Consider an n p matrix X with columns given by thevectors x1 , x2 , . . . , xp (we only consider the case whenp n.) We say that x1 , x2 , . . . , xp are linearly dependent if wecan find multipliers a1 , . . . , ap not all equal to 0, suchthatpXa i xi 0i 121 / 35

06 - LinearAlgebraReviewLinear Dependence and Rank IIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferences If no such multipliers exist, then we say the vectors arelinearly independent, and the matrix is full-rank. In general the rank of a matrix is the maximum number ofxi which form a linearly independent set. The matrix X0 X is a p p matrix. If X has rank p, so does X0 X. Full Rank matrices always have an inverse Square matrices less than full rank never have an inverse22 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesMore Properties of Matrices IDefinition (Positive-Semidefinite Matrix)A symmetric matrix A is said to be positive-semidefinite(p.s.d) if and only ifx0 Ax 0for all xOperations ofMatricesDefinition (Positive-Definite Matrix)Simple LinearRegressionA symmetric matrix A is said to be positive-definite (p.d.) ifReferencesx0 Ax 0for all x, x 6 0. Note that a matrix that is p.d. is also p.s.d.23 / 35

06 - LinearAlgebraReviewMore Properties of Matrices IIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesDefinition (Idempotent Matrices)A matrix P is idempotent if PP P2 P. A symmetricidempotent matrix is called a projection matrix.Operations ofMatricesSimple LinearRegressionReferences24 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionTrace of a Matrix An important operation on square matrices is called thetrace. While not blatantly obvious at the moment, the trace of asquare is encountered throughout statistics and thereforewe’ll define itProperties ofMatricesDefinition (trace)Operations ofMatricesThe trace of a square matrix A {aij } of order n is definedto be the sum of the n diagonal elements of A and is said tobe the symbol tr(A). ThusSimple LinearRegressionReferencestr(A) a11 a22 · · · ann25 / 35

06 - LinearAlgebraReviewVector DifferentiationDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversion Finally we introduce Differentiation for Vectorsd If dβ 1Operations ofMatricesReferencesddβi , thenConsider the vector a,d(β 0 a) adβProperties ofMatricesSimple LinearRegression 2If A is a symmetric matrix, thend(β 0 Aβ) 2Aβdβ26 / 35

06 - LinearAlgebraReviewSimple Linear Regression I Consider a random sample of n observations suchDefiningMatricesYi β0 β1 xi,1 iBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferenceswhere i N (0, σ 2 ) and independent observations. Here the xi are observed and known and we would like toestimate the parameter β. We can rewrite into matrix notation for the nobservations Y1 Y2 . .Yn 1 x111 x21.1 xn1 β0 β1 1 2. norY Xβ 27 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesSimple Linear Regression II One method that can be used to estimate β is throughthe method of least squares The idea is to find the vector β which minimizes thesquared errorsMatrixInversionnXProperties ofMatrices 2i 0 iOperations ofMatrices (Y Xβ)0 (Y Xβ)Simple LinearRegressionReferences That isβ̂ arg min(Y Xβ)0 (Y Xβ)β28 / 35

06 - LinearAlgebraReviewSimple Linear Regression IIIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesLet’s expand this function(Y Xβ)0 (Y Xβ) Y0 Y β 0 X0 Y Y0 Xβ β 0 X0 Xβ Y0 Y 2β 0 X0 Y β 0 X0 Xβwhere the above holds since β 0 X0 Y Y0 Xβ which is a scalar.Simple LinearRegressionReferences29 / 35

06 - LinearAlgebraReviewSimple Linear Regression IVDefiningMatricesNowBasic MatrixOperationsdd(Y Xβ)0 (Y Xβ) (Y0 Y 2β 0 X0 Y β 0 X0 Xβ)dβdβ 2X0 Y 2X0 XβSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionWe can set this equal to zero and thusX0 Y X0 XβNow provided the inverse of X0 X exists we have.Referencesβ̂ (X0 X) 1 X0 Y30 / 35

06 - LinearAlgebraReviewDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesSimple Linear Regression VLet us consider X0 X, its inverse will exist onlyand/or nonsingular. 1 1 1 . 1 1X0 X x1 x2 . . . xn .1if it is full rankx1x2. xn Pnxii 1PnXX 2i 1 xii 1 xiPPThe determinant is det(X0 X) n ni 1 x2i ( ni 1 xi )20 Pnn31 / 35

06 - LinearAlgebraReviewDefiningMatricesSimple Linear Regression VI1 1 .Consider if x 1 1 T, ThenBasic MatrixOperationsSpecial Typesof Matrices0det(X X) nMatrixInversioni 12Simple LinearRegressionReferencesx2i (nXxi )2i 12 n n 0Properties ofMatricesOperations ofMatricesnXWe also see that0XX n nn n which is not full rank. Thus one condition for inversion is thatx 6 132 / 35

06 - LinearAlgebraReviewSimple Linear Regression VIIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesContinuing we can solve for β̂, by our formula for 2 2 inversions we have0(X X)and 11P Pn2n i 1 xi ( ni 1 xi )2 Pn Pn2x xiii 1i 1P ni 1 xin Pn yii 1PX Y ni 1 xi yiT33 / 35

06 - LinearAlgebraReviewSimple Linear Regression VIIIDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesWithout going into all fun of calculating this for you guys, itcan be shown that! ȳ β̂x̄1β̂0Pn (xi x̄)yiPi 1β̂1n(xi x̄)2i 1Simple LinearRegressionReferences34 / 35

06 - LinearAlgebraReviewReferencesDefiningMatricesBasic MatrixOperationsSpecial Typesof MatricesMatrixInversionProperties ofMatricesOperations ofMatricesSimple LinearRegressionReferencesStephen Abbott. Understanding analysis. Springer, 2001.George Casella and Roger L Berger. Statistical inference.Second edition, 2002.EJ Dudewicz and SN Mishra. Modern mathematical statistics.john wilsey & sons. Inc., West Sussex, 1988.Sheldon Ross. A first course in probability. Pearson, ninthedition, 2014.Mark J Schervish. Probability and Statistics. 2014.35 / 35

Sep 07, 2020 · 06 - Linear Algebra Review De ning Matrices Basic Matrix Operations Special Types of Matrices Matrix Inversion Properties of Matrices Operations of Matrices Simple Linear Regression References OverviewI We wrap up the math topics by reviewing some linear algebra concepts Linear algebra

Related Documents:

Robert Gerver, Ph.D. North Shore High School 450 Glen Cove Avenue Glen Head, NY 11545 gerverr@northshoreschools.org Rob has been teaching at . Algebra 1 Financial Algebra Geometry Algebra 2 Algebra 1 Geometry Financial Algebra Algebra 2 Algebra 1 Geometry Algebra 2 Financial Algebra ! Concurrently with Geometry, Algebra 2, or Precalculus

So you can help us find X Teacher/Class Room Pre-Algebra C-20 Mrs. Hernandez Pre-Algebra C-14 . Kalscheur Accelerated Math C-15 Mrs. Khan Honors Algebra 2 Honors Geometry A-21 Mrs. King Math 7 Algebra 1 Honors Algebra 1 C-19 Mrs. Looft Honors Algebra C-16 Mr. Marsh Algebra 1 Honors Geometry A-24 Mrs. Powers Honors Pre-Algebra C-18 Mr. Sellaro .

we are list’ning, list’ning now. O God Your precious word has been a lamp unto our feet ev’ry time we stray and still it lights the shadows out along our path showing us the way. We’re so thankful that You are still speaking You’re still speaking gracious God, for the sake of the world You are seeking we are list’ning, list’ning now.

McDougal Littell Algebra I 2004 McDougal Littell Algebra I: Concepts and Skills 2004 Prentice Hall Algebra I, Virginia Edition 2006 Algebra I (continued) Prentice Hall Algebra I, Virginia Edition Interactive Textbook 2006 CORD Communications, Inc. Algebra I 2004 Glencoe/McGraw Hill Algebra: Concepts and Applications, Volumes 1 and 2 2005

Algebra 2 - Midterm Exam Review The Algebra 2 Midterm Exam must be taken by ALL Algebra 2 students. An exemption pass may be used to exempt the score for the Algebra 2 Midterm Exam. It should be presented to your teacher prior to taking the exam. The Algebra 2 Midterm Exam will consist of 30 multiple choice questions.

Algebra 1 Algebra 1 Practice TestPractice TestPractice Test 3. Solve the following inequality: -20 4 – 2x A. 8 x C. 12 x B. 8 x D. 12 x 4. Which inequality is graphed ? . Algebra 1 Algebra 1 Practice TestPractice TestPractice Test 5. Which equation is represented on the graph? A. y x2 13x 36 B. y x2-13x 36

all digital components available for the Pearson Algebra 1, Geometry, Algebra 2 Common Core Edition 2015. This includes access to the . Screening Test Benchmark Test . Algebra 1 Geometry Algebra 2 Easy access to all textbook answers and solutions

language that is spoken in the environment which they live, since the ability to distinguish the phonemes of one’s language environment is crucial to language acquisition. It is this ability which allows French children adopted by Japanese parents to speak the language of their environment (Jackendoff). Language Development 3 Exposure to language thus influences infants’ acquisition of .