MSMR Resit Report 2023/24

Key Dates

  • Coursework set: 0900 Thursday 20th June 2024
  • Coursework due: 12 noon, Thursday 25th July 2024

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.

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).

Report Formatting

As with USMR, you are welcome to write in RMarkdown 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 directly to pdf

Getting RMarkdown 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

Grading

We are primarily marking your report, and not your code
Grades and feedback are provided for the finished reports, with marks awarded for providing evidence of the ability to:

  • understand and execute appropriate statistical methods to answer each of the questions
  • provide clear explanations of the methods undertaken
  • provide clear and accurate presentation and interpretation of results and conclusions.

Why we still want your code
We still require your code so that we can assess the reproducibility of your work. We also use it as a way to give you extra marks based on the elegance of your coding and/or use of RMarkdown.

  • Five points will be deducted from your final grade if your marker cannot determine how the results in your report were generated in your .Rmd/.R document (for example, if the code produces errors or produces values different from those reported). This means that a 75 out of 100 becomes 70 out of 100.

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: Check that your .Rmd 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).

How to approach the task

For the tasks below, the compiled report (the .pdf file) is expected to include:

  1. Clear written details of the analysis conducted in order to answer the research questions, including transparency with regards to decisions made about the data prior to and during analysis.
  2. Results, in appropriate detail (for instance, a test statistic, standard error and p-value, not just one of these).
  3. Presentation of results where appropriate (in the form of tables or plots).
  4. Interpretation (in the form of a written text referencing relevant parts of your results) leading to a conclusion regarding the research questions.

The R code you submit in the R script or Rmd file should successfully implement the analysis described in A) leading to the same results reported in B). You should also include the code to produce C), unless you have used external software such as PowerPoint.
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.
A reader of your compiled document should be able to more or less replicate your analyses without referring to your R code.

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

134 participants with dementia or Mild Cognitive Impairment (MCI) completed two verbal fluency tests and a brain scan, from which was extracted volume of their superior temporal sulcus (STS), a region thought to be important for verbal fluency.

The data set contains five variables, as described in Table 1.

Table 1: Part A - Data Dictionary
Variable Description
subject subject id
group clinical group: MCI, Alzheimer Dementia (AD), Fronto-Temporal Dementia (bvFTD)
lh_sts_vol STS volume, converted to z-score so 0 corresponds to average STS volume
Test test number
Score verbal fluency score

Using the data in .RData format available at https://uoepsy.github.io/data/Fluency.RData, answer the following research questions:

Research Questions
1. Did verbal fluency decrease between the first and second tests?
2. Did the groups differ in overall fluency? Did they differ in decrease between the first and second tests?
3. Is fluency performance predicted by volume of left STS? Does this vary across test times or groups?

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/data/msmr_2223_nsit2datab.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