Course Materials
This page is the starter hub for lecture notes, code demos, homework links, and language-specific resources.
Weekly Modules (Starter)
| Week | Topic | Page |
|---|---|---|
| 1 | Introduction | Add weeks/week-01.qmd |
| 2 | Linear regression | Add weeks/week-02.qmd |
| 3 | Ridge and lasso | Add weeks/week-03.qmd |
R and Python Example Chunks
These examples are intentionally simple and meant to verify your website can display both languages cleanly.
R Example
set.seed(432)
x <- rnorm(10)
y <- 1 + 2 * x + rnorm(10, sd = 0.3)
fit <- lm(y ~ x)
summary(fit)$coefficientsPython Example
import numpy as np
from sklearn.linear_model import LinearRegression
rng = np.random.default_rng(432)
x = rng.normal(size=(10, 1))
y = 1 + 2 * x[:, 0] + rng.normal(scale=0.3, size=10)
model = LinearRegression().fit(x, y)
{"intercept": model.intercept_, "slope": model.coef_[0]}Add New Week Content
- Create a new page, for example
weeks/week-04.qmd. - Add it to the navigation in
_quarto.yml(or keep this list as the primary index). - Commit and push; GitHub Actions will rebuild and publish.