πŸ“˜ FIT2086: Modelling for Data Analysis

Map of Content

Index for FIT2086 Modelling for Data Analysis β€” the statistics spine of the DS degree. Much of Week 0–1 is revision shared dual-unit with FIT1058_MOC (probability) and FIT1043_MOC (descriptive statistics, R) rather than duplicated.

πŸ“Š Assessment Map

  • Assignment 1 (10%, due W5) Β· Assignment 2 (20%, due W8) Β· Assignment 3 (20%, due W11) βž” carry the whole in-semester half; all involve implementing models in R (LO5).
  • Final exam (50%)
  • LO map βž” LO1 EDA/descriptive (W1–2) Β· LO2 inferential models (W3–5) Β· LO3 predictive models (W6–9, W11) Β· LO4 sampling/simulation/testing (W3, W5, W10) Β· LO5 implement in R (W6–11) Β· LO6 interpret results (W4–11).
  • LO thread so far βž” frame data via probability models; manipulate random variables (pmf/pdf/cdf, joint/marginal/conditional/iid); summarise them by expectations; name the parametric families β€” then fit them by maximum likelihood (W3), judge the fit by bias/variance/MSE, and bound the estimate by a confidence interval (W4). A1 (due W5) sits directly on W3–4 estimation. W6 turns the estimation machinery on a mean that varies with predictors (linear regression) and adds the second-order question β€” which predictors β€” answered by a penalised likelihood. A2 (due W8) sits on W6–7 supervised learning.

🧰 Toolkit Cheatsheets

  • R Toolkit (Cheatsheet) β†’ dual-unit (FIT1043 + FIT2086); FIT2086 adds the simulation / distribution (d/p/q/r) block plus the qnorm/qt critical-value rows

πŸ“… Knowledge Index

Week 0 β€” Self-Study / Revision

Week 1 β€” Modelling, Probability & Random Variables

Week 2 β€” Expectations & Probability Distributions

Studio 1 (run in W2 β€” R foundations, heart.csv / Mushroom.csv / wine.csv)

Week 3 β€” Parameter Estimation, Maximum Likelihood & Estimator Quality

Studio 2 (run in W3 β€” drills the W2 distributions; no new notes, merged into the existing four)

  • Gaussian Distribution β€” -table lookup with linear interpolation ( worked three ways); is why the -rules are scale-free
  • Binomial Distribution β€” term-by-term pmf interpretation; a named sequence has no ; fair-coin tails by hand
  • Poisson Distribution β€” additivity run backwards (/week βž” /day); β€œat least one”
  • Uniform Distribution β€” cdf derivation, by integration, out-of-support probabilities are zero
  • Parametric Probability Distributions β€” the family selection drill (15 described variables βž” verdict + reason)
  • R Simulation and Random Sampling β€” running-mean accumulator + the WLLN convergence plot; why converges faster than

Week 4 β€” Central Limit Theorem & Confidence Intervals

Studio 3 (run in W4 β€” drills the W3 estimation material; train.csv / test.csv)

Week 5 β€” Hypothesis Testing

Studio 4 (run in W5 β€” drills the W4 CLT/CI material; train.csv / test.csv / SP500.csv)

Week 6 β€” Linear Regression & Model Selection

Studio 5 (run in W6 β€” drills the W5 hypothesis-testing material; bpdata.csv / SP500.csv)

  • Hypothesis Testing in R (t.test, binom.test, prop.test) β†’ Parent Framework: Hypothesis Testing (exam + A2 hand skill: mu / alternative / conf.level / var.equal; rv$p.value; binom.test vs prop.test)
  • Tests for Normal Means (z-test and t-test) β€” merged: the bpdata two-sided () vs one-sided () pair, and the three routes to one difference on S&P (approximate / Welch / pooled )
  • Tests for Bernoulli Populations β€” merged: the β€œguess the coin” drill (, vs exact ), the two-sample pooled ( vs exact ), and the binom.test sensitivity sweep
  • Hypothesis Testing β€” merged: ; the leukemia-trial true/false drill at ; the rejection threshold scales with the consequences of a wrong call
  • Confidence Intervals β€” merged: a one-sided alternative returns a bound , not a range; the width sweep on bpdata

πŸ”­ Coming later in the unit (from the unit outline β€” no notes yet)

  • W7 next: supervised learning for categorical targets (classification).
  • Multivariate Gaussian, Dirichlet Β· random sampling, simulation & the bootstrap Β· exploratory vs confirmatory analysis Β· logistic regression Β· Bayesian classification & inverse probability Β· cross-validation & model-performance estimation.

🧭 Suggested Reading Order

(read left→right · bold = assessment-critical)

🎯 Learning Outcomes (key skills per week)

  • W0 βž”
    • classify data (nominal/ordinal/discrete/continuous)
    • compute + interpret centrality (, median, mode) and spread (range, , , percentiles/IQR, boxplots)
    • read Pearson correlation and know independence
    • apply the log/exp identities and differentiate (power/log/exp, product, chain, partial) toward log-likelihoods
  • W1 βž”
    • separate population/sample/model Β· sampling/inference/model-checking Β· three sources of randomness
    • state a pmf (, ); apply inclusion–exclusion
    • joint marginal (sum rule) conditional (product rule); test independence; write the iid product
    • continuous: is not a probability, , split piecewise integrals
    • derive cdf pdf, survival , quantile , mode
    • in R: set.seed, sample, the d/p/q/r family
  • W2 βž”
    • compute , , from a pmf
    • apply linearity and ; know products need independence
    • read population / and why independence
    • state the WLLN; test whether exists at all
    • derive and
    • select a family by support: Β· Β· Β· Β· , with each mean/variance
    • (Studio 1) subset a data frame by condition; write an R function returning a list; factor + table + prop.table; screen predictors with cor
  • W3 βž”
    • separate the three inference tasks: point / interval / hypothesis testing
    • derive an MLE cold: β†’ β†’ β†’
    • quote , , ,
    • use the plug-in distribution for probability statements
    • derive and say what naming the family buys
    • compute , , ; rank by efficiency; test consistency
    • (Studio 2) read a -table by interpolation; justify a family choice from a data description; code an running mean and read a convergence plot
  • W4 βž”
    • state the CLT for sums and derive from it
    • approximate by and by
    • recognise an estimator as an average ⟹ asymptotically normal
    • derive the interval by inverting
    • select among the four CI cases: known Β· unknown Β· difference of means Β· CLT-approximate
    • state coverage correctly (procedure, not the one interval) and read a difference CI containing zero
    • (Studio 3) derive the Bernoulli MLE and explain ML’s boundary overconfidence
    • (Studio 3) fit on train, predict with pnorm, check against empirical proportions, rank models by held-out NLL
    • (Studio 3) code a simulation study returning bias/variance/MSE, and read RelMSE for efficiency vs robustness
  • W5 βž”
    • set up vs and identify one-sided vs two-sided from the wording
    • define a -value as and grade it ( / )
    • select the test: known Β· unknown small- Β· large- approximate Β· two-sample difference
    • compute / by hand and bracket with tabulated criticals
    • test a proportion via the CLT, pooling for two Bernoulli samples
    • explain why a large never proves , and why -thresholding is deprecated
    • (Studio 4) state how CI width scales with and ( data to halve the width); read at any
    • (Studio 4) write calcCI cold and report an interval as a sentence about the population
    • (Studio 4) build a difference-of-means CI for two groups and read it against zero
    • (Studio 4) derive , , MSE, consistency and the CLT limit for the Bernoulli
    • (Studio 4) simulate coverage and explain why plug-in intervals undercover at small
  • W6 βž”
    • separate classification (categorical target) from regression (numerical target)
    • write ; read each as a per-unit change
    • fit by least squares; state , , and the requirement
    • compute and say why it can never select a model
    • derive ⟹ LS ML; quote vs
    • build indicators, polynomial terms, and interaction columns
    • rank predictors by , test , score models by
    • contrast AIC (, overfits) with BIC (, underfits); is significant
    • search all-subsets vs forward/backward stepwise; run step(…, k = log(n)) in R
    • (Studio 5) run t.test with the right mu, alternative, conf.level and var.equal
    • (Studio 5) explain why weakens the evidence, and read a of correctly
    • (Studio 5) judge a large effect with a borderline β€” demand a larger trial, not a verdict
    • (Studio 5) compare approximate , Welch and pooled on one difference, and say which interval is overconfident
    • (Studio 5) test one and two proportions by hand, then check against binom.test / prop.test