Skip to content

Commit 735d8d4

Browse files
committed
corrected some pages
In equations, "\left[ 1_n, \, x \right]" was corrected to "\left[ \begin{matrix} 1_n & x \end{matrix} \right]".
1 parent 8db6a8c commit 735d8d4

6 files changed

Lines changed: 11 additions & 11 deletions

File tree

P/slr-mat.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ where $1_n$ is an $n \times 1$ vector of ones, $x$ is the $n \times 1$ single pr
3737
**Proof:** [Simple linear regression is a special case of multiple linear regression](/P/slr-mlr) with
3838

3939
$$ \label{eq:slr-mlr}
40-
X = \left[ 1_n, \, x \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] \; ,
40+
X = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] \; ,
4141
$$
4242

4343
such that the simple linear regression model can also be written as
@@ -64,7 +64,7 @@ which is a $2 \times n$ matrix and can be reformulated as follows:
6464
$$ \label{eq:E-qed}
6565
\begin{split}
6666
E &= (X^\mathrm{T} X)^{-1} X^\mathrm{T} \\
67-
&= \left( \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \left[ 1_n, \, x \right] \right)^{-1} \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \\
67+
&= \left( \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \left[ \begin{matrix} 1_n & x \end{matrix} \right] \right)^{-1} \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \\
6868
&= \left( \left[ \begin{matrix} n & n\bar{x} \\ n\bar{x} & x^\mathrm{T} x \end{matrix} \right] \right)^{-1} \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \\
6969
&= \frac{1}{n x^\mathrm{T} x - (n\bar{x})^2} \left[ \begin{matrix} x^\mathrm{T} x & -n\bar{x} \\ -n\bar{x} & n \end{matrix} \right] \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \\
7070
&= \frac{1}{x^\mathrm{T} x - n\bar{x}^2} \left[ \begin{matrix} x^\mathrm{T} x/n & -\bar{x} \\ -\bar{x} & 1 \end{matrix} \right] \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \\
@@ -83,7 +83,7 @@ which is an $n \times n$ matrix and can be reformulated as follows:
8383

8484
$$ \label{eq:P-qed}
8585
\begin{split}
86-
P &= X \, E = \left[ 1_n, \, x \right] \left[ \begin{matrix} e_1 \\ e_2 \end{matrix} \right] \\
86+
P &= X \, E = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \left[ \begin{matrix} e_1 \\ e_2 \end{matrix} \right] \\
8787
&= \frac{1}{(n-1)\,s_x^2} \left[ \begin{matrix} 1 & x_1 \\ \vdots & \vdots \\ 1 & x_n \end{matrix} \right] \left[ \begin{matrix} (x^\mathrm{T} x/n) - \bar{x} x_1 & \cdots & (x^\mathrm{T} x/n) - \bar{x} x_n \\ -\bar{x} + x_1 & \cdots & -\bar{x} + x_n \end{matrix} \right] \\
8888
&= \frac{1}{(n-1)\,s_x^2} \left[ \begin{matrix} (x^\mathrm{T} x/n) - 2 \bar{x} x_1 + x_1^2 & \cdots & (x^\mathrm{T} x/n) - \bar{x} (x_1 + x_n) + x_1 x_n \\ \vdots & \ddots & \vdots \\ (x^\mathrm{T} x/n) - \bar{x} (x_1 + x_n) + x_1 x_n & \cdots & (x^\mathrm{T} x/n) - 2 \bar{x} x_n + x_n^2 \end{matrix} \right] \; .
8989
\end{split}

P/slr-mle2.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ where $\bar{x}$ and $\bar{y}$ are the [sample means](/D/mean-samp), $s_x^2$ is t
4343
**Proof:** [Simple linear regression is a special case of multiple linear regression](/P/slr-mlr) with
4444

4545
$$ \label{eq:slr-mlr}
46-
X = \left[ 1_n, \, x \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
46+
X = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
4747
$$
4848

4949
and [weighted least sqaures estimates](/P/mlr-mle) are given by

P/slr-mlr.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ username: "JoramSoch"
2424
**Theorem:** [Simple linear regression](/D/slr) is a special case of [multiple linear regression](/D/mlr) with design matrix $X$ and regression coefficients $\beta$
2525

2626
$$ \label{eq:slr-mlr}
27-
X = \left[ 1_n, \, x \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
27+
X = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
2828
$$
2929

3030
where $1_n$ is an $n \times 1$ vector of ones, $x$ is the $n \times 1$ single predictor variable, $\beta_0$ is the intercept and $\beta_1$ is the slope of the [regression line](/D/regline).
@@ -41,14 +41,14 @@ In matrix notation and using the [multivariate normal distribution](/D/mvn), thi
4141
$$ \label{eq:slr-mlr-s1}
4242
\begin{split}
4343
y &= \beta_0 1_n + \beta_1 x + \varepsilon, \; \varepsilon \sim \mathcal{N}(0, I_n) \\
44-
y &= \left[ 1_n, \, x \right] \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] + \varepsilon, \; \varepsilon \sim \mathcal{N}(0, I_n) \; .
44+
y &= \left[ \begin{matrix} 1_n & x \end{matrix} \right] \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] + \varepsilon, \; \varepsilon \sim \mathcal{N}(0, I_n) \; .
4545
\end{split}
4646
$$
4747

4848
Comparing with the [multiple linear regression equations for uncorrelated errors](/D/mlr), we finally note:
4949

5050
$$ \label{eq:slr-mlr-s3}
51-
y = X\beta + \varepsilon \quad \text{with} \quad X = \left[ 1_n, \, x \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] \; .
51+
y = X\beta + \varepsilon \quad \text{with} \quad X = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] \; .
5252
$$
5353

5454
In the [case of correlated observations](/D/slr), the [error distribution changes to](/D/mlr):

P/slr-ols2.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ where $\bar{x}$ and $\bar{y}$ are the [sample means](/D/mean-samp), $s_x^2$ is t
4242
**Proof:** [Simple linear regression is a special case of multiple linear regression](/P/slr-mlr) with
4343

4444
$$ \label{eq:slr-mlr}
45-
X = \left[ 1_n, \, x \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
45+
X = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
4646
$$
4747

4848
and [ordinary least sqaures estimates](/P/mlr-ols) are given by

P/slr-olsdist.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ where $\bar{x}$ is the [sample mean](/D/mean-samp) and $s_x^2$ is the [sample va
4545
**Proof:** [Simple linear regression is a special case of multiple linear regression](/P/slr-mlr) with
4646

4747
$$ \label{eq:slr-mlr}
48-
X = \left[ 1_n, \, x \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] \; ,
48+
X = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right] \; ,
4949
$$
5050

5151
such that \eqref{eq:slr} can also be written as
@@ -79,7 +79,7 @@ Applying \eqref{eq:slr-mlr}, the [covariance matrix](/D/mvn) can be further deve
7979

8080
$$ \label{eq:b-est-cov}
8181
\begin{split}
82-
\sigma^2 (X^\mathrm{T} X)^{-1} &= \sigma^2 \left( \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \left[ 1_n, \, x \right] \right)^{-1} \\
82+
\sigma^2 (X^\mathrm{T} X)^{-1} &= \sigma^2 \left( \left[ \begin{matrix} 1_n^\mathrm{T} \\ x^\mathrm{T} \end{matrix} \right] \left[ \begin{matrix} 1_n & x \end{matrix} \right] \right)^{-1} \\
8383
&= \sigma^2 \left( \left[ \begin{matrix} n & n\bar{x} \\ n\bar{x} & x^\mathrm{T} x \end{matrix} \right] \right)^{-1} \\
8484
&= \frac{\sigma^2}{n x^\mathrm{T} x - (n\bar{x})^2} \left[ \begin{matrix} x^\mathrm{T} x & -n\bar{x} \\ -n\bar{x} & n \end{matrix} \right] \\
8585
&= \frac{\sigma^2}{x^\mathrm{T} x - n\bar{x}^2} \left[ \begin{matrix} x^\mathrm{T} x/n & -\bar{x} \\ -\bar{x} & 1 \end{matrix} \right] \; .

P/slr-wls2.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ where $1_n$ is an $n \times 1$ vector of ones.
4242
**Proof:** [Simple linear regression is a special case of multiple linear regression](/P/slr-mlr) with
4343

4444
$$ \label{eq:slr-mlr}
45-
X = \left[ 1_n, \, x \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
45+
X = \left[ \begin{matrix} 1_n & x \end{matrix} \right] \quad \text{and} \quad \beta = \left[ \begin{matrix} \beta_0 \\ \beta_1 \end{matrix} \right]
4646
$$
4747

4848
and [weighted least sqaures estimates](/P/mlr-wls) are given by

0 commit comments

Comments
 (0)