Fetch New Hampshire English Learner (LEP) population data
Source:R/fetch_ell.R, R/source_surface_docs.R
fetch_ell.RdLoads and processes NH DOE "LEP Eligible and Monitor Counts" into the canonical tidy English-learner schema. NH reports English-learner population counts at the State-Total and District level, split into two statuses:
current("EL Eligible") – students currently identified as English Learners.monitored("EL Monitor") – students in the 4-year monitored status after attaining English proficiency on the ACCESS for ELLs assessment (former EL).
pct_of_enrollment is each count divided by the published total
enrollment for that entity ("Enroll Count"), a real ratio of two published
values. Counts are real published values with no suppression in this source,
so n_students_lower / n_students_upper equal n_students.
The tidy output keeps NH's el_status column and also exposes standard
cross-state status, metric, and value fields so the ELL
grain is explicit. NH publishes no school-level EL count, so is_school
is always FALSE and nces_sch is always NA.
Usage
fetch_ell(
end_year,
tidy = TRUE,
use_cache = TRUE,
source = NULL,
max_age_days = NULL,
refresh = FALSE
)Arguments
- end_year
School year end (e.g., 2024 = the October-1-2023 / 2023-24 count). Run
get_available_ell_years()to see available years.- tidy
If TRUE (default), returns the long canonical schema (one row per entity x el_status). If FALSE, returns the source-faithful wide frame (one row per entity with current/monitored counts side by side).
- use_cache
If TRUE (default), uses locally cached results when available; set FALSE to force a fresh read from bundled data.
- source
Requested acquisition mode:
"package"(default) or explicit"live"where a runtime producer exists. Retained-only surfaces reject live requests; refresh their files through the documented manual harvest.- max_age_days
Maximum reusable live-cache age in elapsed 24-hour days.
- refresh
Force live retrieval. Valid only in live mode.
Value
Data frame of English-learner data. Tidy columns: end_year, district_id, district_name, school_id, school_name, entity_name, state_id, nces_dist, nces_sch, is_state, is_district, is_school, is_charter, grade_level, el_status, status, subgroup, metric, n_students, value, pct_of_enrollment, denominator, n_students_lower, n_students_upper.
Details
Coverage: 2014-2026 (13 school years). 2012-2013 are excluded – their EL columns are 0 for every district (the ESOL data feed was not yet populated), so they are not-collected rather than real zeros.
Examples
if (FALSE) { # \dontrun{
# 2024 EL counts (October-1-2023)
ell <- fetch_ell(2024)
# Statewide current English-learner count and share of enrollment
ell |>
dplyr::filter(is_state, el_status == "current") |>
dplyr::select(end_year, n_students, pct_of_enrollment)
# Districts with the most English learners
ell |>
dplyr::filter(is_district, el_status == "current") |>
dplyr::arrange(dplyr::desc(n_students)) |>
dplyr::select(district_name, n_students, pct_of_enrollment) |>
head(10)
# Wide format (current + monitored side by side)
fetch_ell(2024, tidy = FALSE)
} # }