MSMR Nullsit Report 2025/26

Own work policy

  • This is an individual assignment and any work submitted should be your own. This applies to both R code and the written report.
  • Please do not post any code or output related to this report on the discussion forum.
  • Similarity checks will be performed, and further investigations will be carried out if assignments from different groups are similar.

Please see the AI policy on Learn.

Instructions

You need to produce a report answering the tasks detailed in the two Coursework Tasks sections. In a separate file, you will also need to provide the R code which exactly reproduces your reported statistical results (that means numbers, tables, figures should match but excludes formatting differences).

We would like to draw your attention at the following differences from the USMR report:

  • There are two parts to the coursework, each based on the two five-week blocks of the course. Address each part of the report as if it was a journal paper or your dissertation. In other words, think of each part of the report as a single standalone study. You should avoid answering a list of research questions, but providing a comprehensive analysis of the data in light of the question(s) of interest.

  • We would recommend that for both parts of the coursework you write a methods section and a results section. The methods section should detail the appropriate analyses you undertook and how they will provide answers to the research questions. The results section should present and discuss your findings, utilising graphics where necessary to illustrate your points. Analyses will draw on the methodologies we have discussed in lectures and weekly exercises.

What you need to submit

You are required to submit 2 documents. Late penalties will apply until you have submitted BOTH files:

  1. Your final compiled report, detailing your analyses, results, interpretation and conclusions. This should not include any R code (or R output printout), but only text, figures, and properly formatted tables.
    • This must be a PDF file (.pdf extension).
  2. A file containing the R code used to generate your statistical results.
    • This can either be an R script (.R extension) or an Rmd file (.Rmd extension).

Page limit

  • Your report should be no longer than 5 pages.

  • You may use an Appendix, which won’t count towards the page limit, in which you can only place tables and figures (no text). The appendix is a good place for supplementary materials. By this we mean figures and tables that are not strictly necessary for the reader to understand and replicate your results, but provide additional context to your report.

Report Formatting

As with USMR, you are welcome to write in RMarkdown/Quarto and knit to word, html, or pdf. You are also welcome to write code in a .R file and copy-paste results into a standalone word processor when writing up. Please just ensure that the final report is exported to a .pdf file.

We don’t mind which of these approaches you take: The important thing to remember is that the data analysis and modelling results in the report should match those produced in your R or RMarkdown file.

If you do wish to do some or all of your formatting in RMarkdown, then we suggest the following readings for help:

Feel free also to post formatting questions on the Piazza discussion forum.

A note on knitting .Rmd/.qmd directly to pdf

Getting RMarkdown/Quarto to knit directly to pdf can be a pain, and formatting is difficult.

We recommend:

  • knit to .html, then Ctrl+P to print to .pdf
  • knit to .docx, then export to .pdf

Submitting your files

Pre-submission checks

Before submitting, we strongly advise you to check that you code runs. The easiest way to check this is to:

  • if using an .R script: Clear your environment, restart your R session (top menu, Session > Restart R), and run your code line by line to see if any errors arise. Alternatively, try clicking “source” in the top right of your script.
  • if using RMarkdown/Quarto Check that your .Rmd/.Qmd compiles (i.e., can you knit your Rmarkdown document into .html/.pdf/.docx without error?)

Filenames

For both files which you submit, the filename should be your Exam Number with the appropriate extension, and nothing else.

For example, a student with exam number B047847 would submit two files:

  • B047847.pdf
  • B047847.R

Where to submit

Go to the Assessments page on Learn, and look for “Assessment Submission”. There you will find two submission boxes (one for each file). For each file you should complete the “Submit File” popup by entering your exam number in the “Submission Title” box.

Late penalties

Submissions are considered late until both files are submitted on Turnitin (see the PPLS policy on late penalties on the MSc Hub).

Grading

We are primarily marking your report, and not your code
As the compiled report will not contain visible R code, a large part of the challenge comes in clearly describing all aspects of the analysis procedure in software agnostic language. A reader of your compiled document should be able to more or less replicate your analyses without referring to your R code.

Grades and feedback are provided for the finished reports, with marks awarded on:

  • Strategy
    • Clear and useful description of the sample used in the analyses.
    • Appropriate analyses conducted to address the research aims, building on methods taught in the class.
    • Clear explanation of the analyses undertaken (without reliance on reference to R code to describe model structures).
    • Transparent and justified explanations of any decisions made about the data prior to and during analyses.
  • Results
    • Appropriate presentation of the relevant results, with sufficient information of the inferential conclusions (for instance, a test statistic, standard error, and p-value, not just one of these). Remember to cite degrees of freedom where needed.
    • Clear and accurate interpretation (in the form of a written paragraph(s) referencing relevant parts of your results and statistics) leading to a conclusion regarding the question.
    • Use of clearly interpretable plots and tables where appropriate to provide additional presentation of findings.
  • Writing & Formatting
    • Clarity of writing and structure, use of appropriate language avoiding unnecessary jargon or overly complex explanations.
  • Code Check
    • Ability of the code to precisely reproduce the analyses, results, and plots presented in the report.

IMPORTANT: Ensuring Reproducibility.
Some functions (such as fa.parallel()) and processes such as bootstrapping, will involve randomly generating numbers, and so results will vary slightly each time you run them. To ensure that your results are reproducible, at the top of your code, use set.seed() to set the random seed. Choose a number (any length) and pass it to set.seed(). Then, every time you run random number generations, it will produce the same results.
For example:

set.seed(8675309) # This is an example, choose your own! 

Any Questions?

This document contains a basic overview of the task and of how to submit it. If you have any questions concerning the coursework report, we ask that you post them on the designated section of the Piazza discussion forum on Learn. If you have a question, it is likely your classmates may have the same question. Before posting a question, please check the on-line board in case it has already been answered.



COURSEWORK TASKS

Part A

Study Aims
The data come from a study investigating factors that predict recovery in cognitive functioning following stroke. 12 hospitals took part in the study, recruiting a total of 204 patients who had suffered a stroke following up at 6 month intervals. At every assessment – baseline (immediately following stroke), 6 months-, 1 year-, 18 months-, and 2 years- post-stroke – researchers administered Addenbrooke’s Cognitive Examination-Revised (ACE-R) to examine changes in participants’ cognitive functioning following stroke. Data was also collected on two additional known risk factors for levels of cognitive functioning: age (measured at baseline) and years of education.

Using the data described in Table 1 and available (in .csv format) at https://uoepsy.github.io/msmr/2526/misc/msmr_2526_nsitA.csv, conduct, interpret and write up a set of analyses that answer the researcher’s research question. Include a brief discussion of the limits of what can be inferred from the analyses.

Research Question
Are changes in cognitive functioning following a stroke dependent on patient’s birthweight?

Table 1: Part A - Data Dictionary
variable description
hospital Hospital Identifier
pid Participant Number
timepoint Visit Number (1-5)
ACER Score on Addenbrooke's Cognitive Examination-Revised (ACE-R). Range 0-100, Scores below 82 indicate dementia
months Months since stroke
birthweight Birthweight (grams)
age Age at baseline (years)
educ Years of education

Part B

A researcher conducted a survey of \(n=1198\) older adults living in the UK and collected items related to their experiences of ageism (6 items, Ageism1–Ageism6), self-esteem (4 items, SEsteem1–SEsteem4), and depression (4 items, Dep1–Dep4). In previous exploratory factor analyses, all three scales showed unidimensionality, i.e. the optimal factor structure was a single factor model.

Using the data described in Table 2 and available (in .csv format) at https://uoepsy.github.io/msmr/2526/misc/msmr_2526_nsitB.csv, conduct, interpret and write up a set of analyses that answer the researcher’s research question. Include a brief discussion of the limits of what can be inferred from the analyses.

Research Question
Does self-esteem partially mediate the links between ageism experiences and depression for older adults?

Table 2: Part B - Data Dictionary
variable description
ID Unique participant identifier
Ageism1 People patronise me because of my age
Ageism2 People exclude me because of my age
Ageism3 The images of people my age I see in the media are all negative
Ageism4 People become frustrated with me because of my age
Ageism5 People don't value my opinion because of my age
Ageism6 Government policies don't adequately take my age group into account
SEsteem1 I feel useless
SEsteem2 I lack any good qualities
SEsteem3 I feel like a failure
SEsteem4 I have nothing to feel proud of
Dep1 I cry often
Dep2 I often feel blue
Dep3 I don't find joy in anything
Dep4 I keep turning negative thoughts over in my mind