STAC32

Applications of Statistical Methods

Ken Butler

bad picture of me in my old office

Welcome to the home page for STAC32. This is the place to look for all things course-related (notes, assignments, announcements etc., linked above) except for assignment hand-ins and marks, which will be on Quercus.

This is an applied course. Expect to be describing the process by which you got your answers, and explaining what the answers mean in the context of the data you are working with: that is to say, using your language skills as well as your statistical skills. Be prepared to show your understanding and insight; this course is about a lot more than “getting the answer”.

In real life, people do Statistics to make decisions or inform actions, and you will be expected to play your full part in that process, both in this course and in your statistical future.

News (most recent at the top

  • 2026-11-08 20:10: another Sunday night “Monday update”:

    • the midterms will be scanned on Monday sometime, and I anticipate that marking will start late on Monday. (This is a Crowdmark exam, which means the exams are marked online and you will get to see your online-marked exam when we are finished.) Your three TAs and I will be busy marking around our other duties.
    • lectures continue:
      • most or all of the week we will be learning more about tidying data.
      • the next thing after that is the windmill case study in which we learn about simple regression in R.
      • in case you were wondering, we’re not doing writing reports in lecture, but you might find it useful to read through the slides for your own interest.
    • tutorial as it stands is for worksheet 8.
    • there is an Assignment 6 open, but it is not due until Nov 16, so that you do not have an assignment to worry about this week.
  • 2026-11-05 20:55: a couple more things today:

    • assignment 4 is marked, and I am about to post the marks. Appeals by the usual procedure between Nov 8 and Nov 15 only (that is, not until after the exam).
    • a student told me after class that the long new r.datatools URL, the one with hub/home on the end, does indeed connect you (or at least connected them) to R 4.6.1, the only problem being that it is a separate system from the old one, so you will have to re-create projects and the like. Give it a try and see if it works for you (you can answer the survey again).
  • 2026-11-05 13:55: I realized that I had rewritten the lecture notes so that one of the questions on worksheet 8 was something you hadn’t seen in lecture. I have just edited worksheet 8; the new version is on the worksheets page, moving the old stuff to an Extra (that you can read about if you feel so inclined, probably after the exam).

  • 2026-11-05 10:30: assignment 5 is closed. My solutions are on the assignment solutions page. You already have access to worksheet 7 solutions, on the worksheets page. There will be a worksheet 8 up this afternoon on tidying data, for tutorial next week, with solutions to come later. The material on tidying data is, as you know, not on the midterm.

  • 2026-11-04 08:30: re: the the new datatools: this is supposed to be the full link. Try it and see if it works any better (or not).

  • 2026-11-01 15:25: This week’s “Monday update” is on Sunday. I am sitting outside on the balcony, which seems all wrong in November, but so it is:

    • Lectures:
      • Analysis of Variance. The end-point of what might appear on the midterm will be during Tuesday’s lecture; I will announce when we have gotten there.
      • maybe a bit of tidying on Thursday.
    • Tutorial: worksheet 7 on the worksheets page, with solutions to help you prepare for the exam. I’ll alert the TAs that you might also have exam course-material questions (for example, from the old exams). The TAs are the wrong people to ask about exam procedures; see below for what to do about those.
    • Assignment 5 is due on Monday night as usual. Assignment 6 will open on Wednesday but is not due until Nov 16 (so that you do not have to worry about it while you also have an exam to think about).
    • Worksheet 8 will be posted after this week’s lectures, for tutorial on Nov 11. (After the midterm, worksheets will be ahead of assignments by two rather than one.)
    • The midterm is on Friday night, Nov 6. See Quercus announcement for time and place. I hope I have answers to all your procedural questions: see note on 2026-10-21 15:45. If I missed anything, ask on Quercus discussions.
  • 2026-11-01 15:15: I made a survey in Quercus (under Quizzes) to see how many of you can access the new r-staging.datatools. The way to see what is happening is to use the link above, and see where you end up. The likely two possibilities are (i) that it works and you are running R 4.6.1 (check the Console window bottom left) and (ii) you get redirected back to the old r.datatools and you are running R 4.3.2 as before. I’m trying to find out whether it works for some people, or for nobody yet. There are no wrong answers on the survey, despite what your “grade” might suggest.

  • 2026-10-30 11:55: to follow up on r-staging.datatools: at least one student has tried to access this (following the instructions from 2 days ago) and got redirected back to the old r.datatools running R 4.3.2 (the old version). I have pinged the IT people to tell them that this has happened, so until this is resolved, you may not have access to the new version of R yet. Of course, in the most annoying way possible, “it works for me” and you are supposed to have the same access permissions as I do.

  • 2026-10-28 11:35: We have a midterm. It has 26 questions, of similar type to what you have seen on worksheets and assignments, worth a total of 64 points. See the note on 2026-10-21 15:45 for more about what to expect on the exam.

  • 2026-10-28 10:45: I forgot to post my solutions to assignment 4. They are on the assignment solutions page now.

  • 2026-10-26 12:00: It looks as if r.datatools has a working new version of R. Go here, and log in with your UTorID and password as usual. To make documents render properly, put this line

options(crayon.enabled = FALSE)

at the top of your code, just above your library(tidyverse), and then your rendered document should have no additional junk in it. This means that you can feel free to use the new version for assignments from here on out and run the code as it appears in lectures.

  • 2026-10-23 12:15: Assignment 3 is marked, and I will post the marks in a few minutes. Appeals by the same procedure as assignment 1 (using the subject heading “Assignment 3 appeal”) between Oct 26 and Nov 2 only.

  • 2026-10-22 15:30: some more things:

    • Assignment 5 is open now, but is not due until Monday November 2 (so that you have nothing due from me during reading week)
    • There are old exams on the course website. Midterms can be anything from very early in the course to very late, so the material tested on them will vary from year to year (our midterm is late this year). These can benefit you if you do an exam under exam conditions (in other words, as one of the last things in your preparation) and grade yourself by then looking critically at your work and my solutions, so that you can discover where your knowledge is strong and where it is weaker. If you just read my solutions, you are “learning my solutions”, which will not prepare you for the upcoming exam because that will be different from past ones.
    • I’ll tell you during the lecture on Tuesday after reading week when we have reached the end of the material that is fair game for the exam. It won’t be all of the ANOVA stuff, but it will be more than we talked about today.
    • If I figure out how to get Quarto documents to render nicely on the new r.datatools, I’ll let you know.
    • And, of course, wishing you a reading week of rest, or catching up, or whatever you plan to do.
  • 2026-10-22 15:15: worksheets:

    • worksheet 6 solutions are up on the worksheets page.
    • I added an analysis of variance question to worksheet 7 (along the lines of the end of today’s lecture and what you will see on the Tuesday after reading week). This is also on the worksheets page.
    • I don’t normally post worksheet solutions early, but since you have an exam coming, I thought I would also post my solutions to worksheet 7, on the worksheets page. A reminder that simply looking at my solutions will not help you. You learn by making an honest effort to solve the problems in the worksheet yourself, and only then looking at my solutions.
  • 2026-10-21 15:45: about the midterm (see the Quercus announcement for time and place):

    • this will be a handwritten exam (yes, including code, but that’s the way it goes)
    • coverage is up to and including the Tuesday before the midterm. There will also be a lecture on Thursday that week; that material will not be on the midterm, but you can count on it being on the final.
    • all my exams are open-book: you can bring any printed material you wish (no devices of any kind)
    • the point of my exams is to see how well you can problem-solve, such as
      • can you come up with code to solve a problem I give you?
      • can you explain what a piece of output is telling you about a data set?
      • can you make a properly justified conclusion from an analysis (whose output I give you)?
    • anything you bring, to be of any value to you, will need to be organized so that you can quickly find what you are looking for. This needs to be part of your preparation for the exam.
    • an open-book exam is not an excuse to skip studying for it. If the material you bring is not well-organized, you will run out of time. I do not want to test your memory; I want to test your ability to use your materials to solve problems, a higher level of thinking.
    • expect to see something like 28 questions like the ones on worksheets and assignments, grouped together by data set, bearing in mind that if I am asking about output, I will give you the output (rather than you having to generate it yourself like on an assignment).
    • at the exam, you will get a booklet of questions with spaces to write your answers in (which you hand in at the end), and also a booklet of numbered Figures that the exam questions refer to (which you can keep after the exam).
    • (added 2026-11-01) if you miss the midterm for any reason, its weight automatically shifts to the final exam. You do not need to tell me that you are missing the midterm. There is no makeup midterm. If you write the midterm and your final exam percent is higher, the final exam counts instead of the midterm. Thus, writing the midterm is a kind of insurance, but if you are sick, particularly if it is something contagious, you do better to stay home.
  • 2026-10-21 15:30: I think we have a new version of r.datatools to test out. I can certainly access it, as of this afternoon, and it seems to be working for me. They asked for the Quercus link to the course, so I assume that you have access too, via the same procedure as the old r.datatools. If you get a 503 error, it means you don’t have access yet (try again later), but if you do have access, try it out with filter_out, when_any, when_all, recode_values, replace_values and the other things that didn’t work before. Some things to adjust:

    • tools/global options/code/ uncheck “use native pipe operator”
    • tools/global options/R Markdown show output preview in (select) Viewer Pane
    • Rendering is not working properly. When I figure out what to adjust, I’ll let you know.
  • 2026-10-20 14:30: I had a visit a few minutes ago from a student who did the same thing as me on question 2 of assignment 3 and got a different histogram! The reason this happened seems to be simply that the student used r.datatools and I used R on my own computer. I have added some extra discussion to my solutions in question 2 (and also in question 5: see the additional footnote), and have alerted the grader so that your work should be marked fairly.

  • 2026-10-20 11:40:

    • I made some small edits to this week’s lecture notes on matched pairs and Mood’s median test. You might like to download the latest versions.
    • Today (Tuesday) it looks as if I will talk about all of matched pairs and make a start on Mood’s median test.
  • 2026-10-16 12:55: coming up next week:

    • lectures:
    • worksheet 6 on the last bit of power and the sign test, for tutorial on Wednesday
    • Assignment 4 is due on Monday (back to the usual schedule). Assignment 5 will open on Wednesday but will not be due until after Reading Week (Nov 2).
  • 2026-10-16 12:50: assignment 3 is now closed. My solutions are on the assignment solutions page.

  • 2026-10-15 13:15:

    • assignment 2 is marked, and marks will be posted shortly. You should be able to resolve any questions you have about your mark by referring to the rubric and my solutions on the assignment solutions page; if you think there has been an error in the marking of your assignment, you may appeal following the instructions for assignment 1, between Oct 18 and Oct 25 only. (Use the subject heading “Assignment 2 appeal” this time, of course.)
    • there seems to be a problem in Quercus that displaying a dataframe doesn’t always display on Quercus even though the html file does include code to display the dataframe. (I checked.) You should have full credit for “displaying” your data if you include code for doing so.
    • this is distinct from the problem you might have encountered with displaying graphs (that is solved by the embed-resources thing). I expect you to get that correct.
  • 2026-10-14 21:30: my solutions to worksheet 5 are on the worksheets page, before I forget (again).

  • 2026-10-14 13:40: worksheet 6 is on the worksheets page. At this moment, the first two problems are doable now, and the rest will be after tomorrow’s lecture.

  • 2026-10-14 11:45: we have movement on the r.datatools issue: they are going to “spin up a staging environment” for us to test. I’ll let you know when that is live.

  • 2026-10-11 15:15: Coming up this week:

  • 2026-10-08 11:55: Worksheet 5 is up on the worksheets page.

  • 2026-10-08 10:30: some assignment things:

    • Assignment 2 is closed. My solutions are up on the assignment solutions page.
    • Assignment 3 is open, and is due next Tuesday night (because Monday is Thanksgiving).
    • Assignment 1 is marked, and I am about to post the marks. Read your marked assignment along with my solutions. There is a lot of extra information in my solutions that is worth your while reading even if you got full marks on a question.
    • You may only appeal your mark on an assignment if there has been a clear error, such as a question that was not marked at all. Disagreeing with the marker’s judgement is not an error. To submit an appeal, email me with the subject line “Assignment 1 appeal”, between October 11 and 18 only. In your email you must clearly describe the error in marking in your assignment, compared to my solutions and the rubric, and make your case for a different mark. At the end of the appeal period, I will look at the appeals. Please note that I have the right to remark the whole assignment, and marks can go down as well as up. The relevant course policies are in section 3, items 19–23.
    • My philosophy on appeals is similar to this, which you should read. Please note the words “firmly and with a critical eye” there. Of course, if you wish to submit an appeal in this course, follow my policy (above), not Professor Rosenthal’s.
  • 2026-10-07 23:40: My worksheet 4 solutions are on the worksheets page, a bit later than intended.

  • 2026-10-04 22:30: the upcoming week is this:

    • assignment 2 is due on Monday night
    • lectures:
    • worksheet 4 on the worksheets page (it should all be doable now) with solutions going up Wed night
    • assignment 3 will open on Wed night
    • a reminder that Mon Oct 12 is Thanksgiving, so no classes (in your other courses) that day. Assignment 3, that would have been due that day, is due on Tuesday instead.
  • 2026-10-01 10:30: worksheet 4 for next week’s tutorial is on the worksheets page. Depending on how far we get today, some of it may make more sense after next Tuesday’s lecture.

  • 2026-10-01 00:01: my solutions to assignment 1 are up on the assignment solutions page.

  • 2026-09-30 19:30: my solutions to worksheet 3 are up on the worksheets page. Assignment 2 is now open.

  • 2026-09-27 12:30: upcoming this week:

  • 2026-09-25 13:00: I wrote a (rather long) thing for you with workarounds for filter_out etc, for use if you are working on r.datatools. The new functions are all in section headings, so you can ctrl-F to find the one you want, and then read the section below it to find out what to do instead. On the course lecture notes page, you can also get at all the code for this document should you wish to run it yourself without typing everything in.

  • 2026-09-24 13:20 edited 15:30: Questions for worksheet 3 are on the worksheets page. These were written anticipating that these and similar things would be working: filter_out, when_any and the recode_values and replace_values that we saw today. It looks as if I will be writing something for you with workarounds for these, depending on how quickly the r.datatools people get around to updating R and packages. (You’ll need either these functions or workarounds for them for assignment 2, which opens next week.) In the meanwhile, this writeup describes the new functions and how they replace the old ones, which you might find helpful in thinking about workarounds. I’m using this to guide my writeup for you.

  • 2026-09-23 22:00: Worksheet 2 solutions are on the worksheets page, and Assignment 1 is open, due on Monday night. Worksheet 3 should go up after the Thursday lecture; some of it you may need to wait until Tuesday to make sense of.

  • 2026-09-22 14:05 updated 14:30 and 16:05:

    • if you are using r.datatools, it has an old version of tidyverse, and you probably don’t have filter_out, when_any, and when_all. I thought I had a workaround for this, but I’m not so sure (after student experiences today) that I do after all. Investigating.
    • Update: I don’t think I can solve this one, so have filed a ticket requesting the most recent version of R and packages at the other end. Will keep you posted. (R on your own machine will work, if you want to investigate that.)
    • Updated update: I got a response “We’re working on it and I’ll get back to you with updates soon.” We’ll see how soon “soon” is.
  • 2026-09-21 12:00: Our midterm will be on November 6. See Quercus announcement for time and place. According to course policy, there is no makeup midterm. If you have something else at the same time, it is up to you whether you (i) make arrangements to not be at the other thing, or (ii) transfer the weight of this midterm to the final exam (not recommended if you can avoid it).

  • 2026-09-18 11:30: progress report:

    • We have a bit more of numerical summaries to finish next week.
    • After that comes choosing things from dataframes, and then recoding, replacing, and looking up.
    • After that (that is, about Sep 29) we will get into statistical inference with one-sample and two-sample \(t\)-tests. If your understanding of these ideas is a bit rusty, now would be a good time to go back to your notes from your first course and review them.
    • Worksheet 2, for the September 23 tutorial, is on the worksheets page. Solutions to this will be posted on Wednesday evening on the same page. If you are having trouble with using R, or with the ideas in the worksheets, the tutorial is the place to get help.
    • After tutorials are done on Wednesday, Assignment 1 will open, and will be due on Monday night (at the usual 11:59pm). There are no extensions to this due date, and a late penalty applies. (You’ll remember from the course outline that the worst two assignments are dropped.) The only exception is if you have a verified accommodation with Accessability that includes extensions on assignments, and then the maximum extension is two days. If this applies to you, you need to claim your extension before the original due date.
    • After the assignment closes (Wednesday 30th), I will post my detailed solutions.
    • Looking even further ahead, the midterm will be outside of class time, scheduled by the Registrar’s office. I will share the date as soon as it is confirmed.
  • 2026-09-17 16:25: I took a look at the “assignment 0” that have been submitted:

    • I was mainly looking to see whether you have submitted the right kind of thing with at least one graph in it, and if you have done that, you should have 1 point.
    • I was not especially picky about what you submitted for this one, but if I really didn’t like something, you’ll have a comment as well.
    • Depending on whether I have set up the late penalty right, you might have less than 1 if you submitted after midnight Wed, but any non-zero score means you did the work right.
    • If you got 0, read the comment to see what happened, and feel free to try again (you have unlimited attempts, and “assignment 0” will stay open). I will check in again in a few days.
    • If you didn’t attempt “assignment 0” at all, my sympathy for you if you have trouble submitting the first real assignment will be limited.
  • 2026-09-17 11:00: if you want to make an early start, worksheet 2 is up on the worksheets page. Most of this should be doable after Tuesday’s lecture, and the rest of it will be after today’s.

    • Note that this, and future worksheets, don’t come with answers. This is because your learning comes from figuring out what to do and how to do it in order to answer the questions. Next week after tutorial, I will post my (very detailed) solutions, and you’ll be able to see how you did. This will help you prepare for the assignment that follows the worksheet: assignments will open Wednesday night after tutorial and will be due on the following Monday night.
  • 2026-09-14 12:00 edited 12:30:

    • Reminder that tutorials start this week (on Wednesday). One of the tutorials (#3, the one at 12 noon) has changed room. You should have email if this affects you; the room change will be on your Acorn. I don’t think the new room has as many plugins as the IA rooms, so make sure your laptop has some battery left.
    • Some reading for you (not about Statistics): Your edge is patience, not genius.
  • 2026-09-13 14:00: Normally I would put up a Monday update for the week to come, but I seem to be doing it on Sunday this week (edited on Monday to include links):

    • You may have found Thursday’s lecture a lot to take in. The story is “don’t panic”: the big picture is that there are data files of different kinds that you need to be able to read in, which could be either in files on your computer or on the web, and whatever comes your way, you need to be able to identify the kind of thing you are faced with, and find in your notes the instructions for dealing with it.
    • Tuesday’s lecture may be similar, in that we meet code for a lot of different graphs. This may be easier in that you have seen most of these graphs before and you know when to use which one; the new part is going to be finding the code that makes the graph you want. If you get confused during lecture, you may like to practice working through the lecture code by yourself afterwards (so that you are not rushed), thinking about “what am I doing?” and “why am I doing it?”.
    • Lectures for the upcoming week:
    • Tutorials start on Wednesday. You’ll be working through worksheet 1, with a TA to help you if you get stuck or confused. (You might like to start the worksheet before tutorial, and make a note about where things start to get confusing so you can ask about it.) Make sure you get to where you practice handing in an assignment, so that when the real thing comes around, you will know what to do.
    • Looking further ahead, worksheet 2 will come out next week, and after that, Assignment 1 will open (based on the first two worksheets).
    • My course plan is here, subject to changes as we go. (I am trying to get away from Google Sheets.)
  • 2026-09-10 15:15: As a result of a conversation in office hours, on the lecture notes page, I added some instructions about how you can use the files in the Code column to get a copy of the code that I run in class.

  • 2026-09-10 10:45: data files for today’s class:

  • 2026-09-07 20:20:

  • 2026-09-07 20:00: The lectures in this course will not be recorded. This is an in-person course at an in-person university, and you are expected to attend lectures, pay attention, and take notes. This is the route to success in this course (or indeed any course). In my experience, students who do not attend lectures struggle in the course, and especially on the exams. My lecture slides are available (see the lecture notes link above), but be aware that I say a lot more than is on them. In office hours, I am happy to answer specific questions, but I will not reteach anything that was in the lecture.

  • 2026-09-03 15:30: A reminder that if you are on the waitlist for a course (this course or any course), all you can do is wait and see what happens. It is not appropriate to ask your instructor for special treatment. You should have backup plans in case you don’t get into the course you are waitlisted for. If you are close to graduation, it is up to you to take advantage of your early enrolment date to get into the courses you want. The waitlist in STAC32 tends to move very slowly.

  • 2026-08-31 17:00 (edited 17:30): Course starts the day after Labour Day. I am (I hope) ready to go, and I hope you are too. Three quick things:

    • we have a Quercus page. The main reason for having this is as a place for you to:
      • submit assignments
      • see your marked assignments and exams
      • ask course-material questions on the Discussion board.
    • the course outline should you wish to see it before the course begins.
    • if you applied to join the Applied Statistics Minor program in the August round of applications, you should be receiving a decision (on Acorn) in the next day or two.
  • 2026-08-24 12:50: Just had a look at our classrooms (all in IA). The lectures are in “The Keystone”. The tutorials are in regular classrooms (albeit ones with lots of plugins), so you will need to bring a laptop for the tutorials, or at least be willing to share one with a friend. (Tutorials start in week 2 as usual.)

  • 2026-08-20 13:15: I have found space in STAC32 for a few students from the waitlist, and have asked for them to be added to the course. My criteria were:

    • registered in the Statistics Applied Minor program
    • have 13 or more credits now (and so may be able to graduate by next summer).

    I may be able to do something similar for students in the program who reach 13 credits by the end of the summer semester, but this is not a guarantee, and you should have backup plans.

    Students not in the Statistics Applied Minor program, regardless of the number of credits they have completed, should not expect to make it into STAC32, and students in the program who have fewer credits will have to take their chances with the waitlist. There is an August application period for the program, but it is unlikely that there will be room in this year’s STAC32 even for successful applicants then.

  • 2026-08-05 14:00: my position on AI and the use of devices in class.

  • 2026-08-05 11:15: the course has a waitlist. If you are currently on it, I advise you to have backup plans in case you don’t make it in. Everybody on the waitlist wants to be in the course, so you will need to wait your turn.

  • 2026-06-29 18:00 (edited 2026-08-05 11:45): time to open things up for the fall 2026 edition of this course:

    • I will be checking prerequisites. To take STAC32, you must have completed (by the time STAC32 starts in September) either STAB27 or PSYC08 or MGEB12, or another equivalent that has already been approved by me. If you have not completed one of these courses by then, you will be removed from STAC32.
    • Notes:
      • you need to have completed one of these courses to be considered for admission to the Applied Statistics Minor program.
      • Psychology is revamping its Statistics courses; if you have taken PSYB07 but it was impossible for you to take PSYC08 because it was never offered in a semester after the one in which you took PSYB07, you should take the new PSYC06 as your second course, which will in any case prepare you better for the program than the new PSYB06 does.
    • Program FAQ.