Enrollment and Follow-Up Monitoring Plots
9.5 Enrollment and Follow-Up Monitoring Plots
Reading 1
3 / 10
9.5 Enrollment and Follow-Up Monitoring Plots
Enrollment over time is one of the most common clinical study monitoring plots. A cumulative enrollment curve helps investigators see whether recruitment is on track. The following code creates a cumulative enrollment plot:
```r
cumulative_enrollment <- prepared_data |>
distinct(participant_id, enrollment_date, site) |>
arrange(enrollment_date) |>
mutate(cumulative_participants = row_number())
cumulative_enrollment |>
ggplot(aes(x = enrollment_date, y = cumulative_participants)) +
geom_line() +
labs(
title = "Cumulative Enrollment Over Time",
x = "Enrollment date",
y = "Cumulative participants"
)
```
If enrollment should be reviewed by site, the plot can use color:
```r
site_cumulative_enrollment <- prepared_data |>
distinct(participant_id, enrollment_date, site) |>
arrange(site, enrollment_date) |>
group_by(site) |>
mutate(cumulative_participants = row_number()) |>
ungroup()
site_cumulative_enrollment |>
ggplot(aes(x = enrollment_date, y = cumulative_participants, color = site)) +
geom_line() +
labs(
title = "Cumulative Enrollment by Site",
x = "Enrollment date",
y = "Cumulative participants",
color = "Site"
)
```
This chart may become crowded if many sites are included. For many sites, faceting may be better:
```r
site_cumulative_enrollment |>
ggplot(aes(x = enrollment_date, y = cumulative_participants)) +
geom_line() +
facet_wrap(~ site) +
labs(
title = "Cumulative Enrollment by Site",
x = "Enrollment date",
y = "Cumulative participants"
)
```
Follow-up monitoring can use window status:
```r
prepared_data |>
count(site, day28_window_status, name = "participants") |>
ggplot(aes(x = site, y = participants, fill = day28_window_status)) +
geom_col() +
coord_flip() +
labs(
title = "Day 28 Follow-Up Window Status by Site",
x = "Site",
y = "Participants",
fill = "Window status"
)
```
This chart supports action because it shows where visits are overdue, too early, too late, or within window. It should be generated from a clearly defined window rule.