Learn R Programming

serosv (version 1.1.0)

parvob19_ew_1996: Parvo B19 serological data from England and Wales in 1996 (line listing)

Description

A seroprevalence survey testing for parvovirus B19 IgG antibody, performed on large representative national serum banks in Belgium, England and Wales, Finland, Italy, and Poland. The sera were collected between 1995 and 2004 and were obtained from residual sera submitted for routine laboratory testing.

Usage

parvob19_ew_1996

Arguments

Format

A data frame with 5 variables:

age

Age of individual

seropositive

If the individual is seropositive or not

year

Year surveyed

gender

Gender of individual

parvouml

Parvo B19 antibody units per ml

Examples

Run this code
# Reproduce Fig 4.5 (right upper panel), p. 68
# NB: This figure will look different to that of in the book, since we
# believe that the original authors has made some errors in specifying
# the sample size of the dots.
library(dplyr)
df <- parvob19_ew_1996 %>%
  mutate(age = round(age)) %>%
  group_by(age) %>%
  summarise(pos = sum(seropositive), tot = n())
plot(df$age, df$pos / df$tot,
  cex = 0.02 * df$tot, pch = 16, xlab = "age", ylab = "seroprevalence",
  xlim = c(0, 82), ylim = c(0, 1)
)

Run the code above in your browser using DataLab