Skip to contents

Downloads and processes Keystone exam data from the Pennsylvania Department of Education. Keystone exams are end-of-course assessments in Algebra I, Biology, and Literature (grade 11).

Usage

fetch_keystone(end_year, level = "school", tidy = TRUE, use_cache = TRUE)

Arguments

end_year

School year end (e.g., 2024 for 2023-24). Valid years: 2015-2025 except 2020 (COVID cancellation).

level

Data aggregation level: "school" (default), "district", or "state"

tidy

If TRUE (default), returns data in long format with proficiency levels as rows. If FALSE, returns wide format.

use_cache

If TRUE (default), uses locally cached data when available. Set to FALSE to force re-download from PDE.

Value

Data frame with Keystone assessment data

Examples

if (FALSE) { # \dontrun{
# Get 2025 school-level Keystone data
keystone_2025 <- fetch_keystone(2025)

# Get state-level summary
keystone_state <- fetch_keystone(2025, level = "state")
} # }