Fix math display

This commit is contained in:
Nora Wickelmaier 2025-06-20 14:11:52 +02:00
parent 40fdb67b67
commit 78abc7602b
2 changed files with 20 additions and 12 deletions

View File

@ -1,7 +1,13 @@
Exercise: Junior School Project
================
Nora Wickelmaier
2025-06-20
---
title: "Exercise: Junior School Project"
author: "Nora Wickelmaier"
output:
md_document:
variant: gfm
preserve_yaml: true
kramdown:
math_engine: mathjax
---
Load the Junior School Project collected from primary (U.S. term is
elementary) schools in inner London in R. You might need to install the
@ -71,11 +77,11 @@ aggregate(gcraven ~ school, dat, mean) |> head()
## 5 5 5.075722e-16
## 6 6 0.000000e+00
3. Create a plot with `lattice::xyplot()` with `gcraven` on the
$x$-axis and `math` on the $y$-axis and one panel for each school.
Use `type = c("p", "g", "r")`. You can also use `ggplot2` if you
want to. What would be your conclusion about the need for
school-specific slopes based on this plot?
3. Create a plot with `lattice::xyplot()` with `gcraven` on the x-axis
and `math` on the y-axis and one panel for each school. Use
`type = c("p", "g", "r")`. You can also use `ggplot2` if you want
to. What would be your conclusion about the need for school-specific
slopes based on this plot?
<img src="jsp_files/figure-gfm/unnamed-chunk-7-1.png" style="display: block; margin: auto;" />
@ -108,9 +114,11 @@ aggregate(gcraven ~ school, dat, mean) |> head()
&~~~ + \beta_{4}\,mraven_i + \beta_{5}\,(gcraven_{ij} \times mraven_{i})\\
&~~~ + \upsilon_{0i} + \upsilon_{1i}\,gcraven_{ij} + \varepsilon_{ij}
\end{align*}
$$ with
$\boldsymbol\upsilon \sim N(\boldsymbol 0, \boldsymbol{\Sigma}_\upsilon)$
i.i.d., $\varepsilon_{ij} \sim N(0, \sigma^2)$ i.i.d.
$$
with
$$\boldsymbol\upsilon \sim N(\boldsymbol 0, \boldsymbol{\Sigma}_\upsilon)$$
i.i.d., $$\varepsilon_{ij} \sim N(0, \sigma^2)$$ i.i.d.
5. Interpret the parameters of the model:

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.2 KiB

After

Width:  |  Height:  |  Size: 7.4 KiB