Kaisa_2012_3_photo by Veikko Somerpuro

5.2.2020 at 08:00 - 25.2.2020 at 23:59


Petteri Piiroinen

Published, 4.4.2020 at 18:42


I can finally announce that the grading is done and can be found from the page https://courses.helsinki.fi/fi/mat22005/130687833. The course grade should be on your Weboodi in few days.

Thank you all for participating to the course. I hope you have stayed and will continue stay healthy. The points of the exercises can be found from the page https://courses.helsinki.fi/fi/mat22005/130408974

I will add the missing R files from one week (thank you for donating your code to help getting those).

With best,



Fri 6.3.2020
12:00 - 14:30


Bachelors's program of mathematical sciences.

Mandatory course in Intermediate studies in Statistics (MAT221). Also mandatory in MAT221, and optional in MAT020.

Basic studies in statistics (MAT120), basic studies in mathematics (MAT110). From the subject studies of statistics the courses MAT22001 and MAT22002 (Probability IIa and IIb) and their background requirements, or the equivalent background knowledge (basics in likelihood and bayesian inference, R programming, usual one- and multidimensional probability distributions, analysis of discrete one- and multidimensional distributions with (joint) probability mass functions, analysis of continuous one- and multidimensional distributions with (joint) probability density functions, change of variables formula for one- and multidimensional (joint) density functions, usual statistics of distributions and estimation based on these statistics, expectation, (co)variance and covariance matrix, and the basic properties of these, conditional distribution and conditional expectation, hierarchical definition of multidimensional distributions with marginal and conditional distributions, multinormal distribution and its properties, law of large numbers, central limit theorem and some approximations based on these limit results.)

Recommended studies (optional): Statistical inference II (MAT22003), Linear models I (MAT22004), Linear algebra and matrix computations III (MAT22011)

After the course the student should be able to do Bayesian inference both analytically, and using simulations, and to be able to use R and Stan to perform these simulations.

For students of statistics the recommended time for the course is the autumn of the third year of the studies.

The course is held on period II (second period of the autumn).

  • Topics of the course:
    • Basics of the Bayesian inference: likelihood, priori and posteriori
    • Bayesian inference for models with one parameter
    • Bayesian for multiparameter models
    • Predicting new observations using the posterior predictive distribution
    • Simulating from the posterior distribution using R and Stan
    • Quantifying the uncertainty of the parameter estimates using posterior intervals, statistics, and plots
    • Hierarchical models
    • Linear regression in the Bayesian framework
    • Model selection

Recommended (optional) background material : Gelman et al.: Bayesian data analysis, 3:rd edition (2013).

Stan- and R exercises in the exercise session.

Grading is mainly determined by the final exam, but you can also gain some points from doing the home exercises.

Lectures and exercise sessions