Util_Invalsi_filter {SchoolDataIT}R Documentation

Filter the Invalsi data by subject, school grade and year.

Description

This function filters the database of Invalsi scores (see Get_Invalsi_IS) by school year, education grade and subject and returns a dataframe in wide format. Each row corresponds to one territorial unit (either municipality or province); the numerical variables are three (the mean score, the score's standard deviation and the students coverage percentage) for each selected subject.

Usage

Util_Invalsi_filter(
  data = NULL,
  subj = c("ELI", "ERE", "ITA", "MAT"),
  grade = 8,
  level = "LAU",
  WLE = FALSE,
  Year = 2023,
  verbose = TRUE,
  autoAbort = FALSE
)

Arguments

data

Object of class tbl_df, tbl and data.frame. The raw Invalsi survey data that has to be filtered, obtained as output of the Get_Invalsi_IS function. If NULL, it will be downloaded automatically, but not saved in the global environment. NULL by default

subj

Character. The school subject(s) to include, among "Englis_listening"/"ELI", "English_reading"/"ERE", "Italian"/"ITA" and "Mathematics"/"MAT". All four by default.

grade

Numeric. The school grade to chose. Either 2 (2nd year of primary school), 5 (last year of primary school), 8 (last year of middle shcool), 10 (2nd year of high school) or 13 (last year of school). 8 by default

level

Character. The level of aggregation of Invalsi census data. Either "NUTS-3", "Province", "LAU", "Municipality". If an input dataframe is provided, please select the same level of aggregation. "LAU" by default

WLE

Logical. Whether the variable to choose should be the average WLE score rather that the percentage of sufficient tests, if both are available. FALSE by default

Year

Numeric or character value. Reference school year for the data (last available is 2022/23). Available in the formats: 2022, "2021/2022", 202122, 20212022. 2023 by default

verbose

Logical. If TRUE, the function informs about the time needed. TRUE by default.

autoAbort

Logical. In case any data must be retrieved, whether to automatically abort the operation and return NULL in case of missing internet connection or server response errors. FALSE by default.

Value

An object of class tbl_df, tbl and data.frame. For all subjects and school grades, the variables indicate:

Examples




Util_Invalsi_filter(subj = c("Italian", "Mathematics"), grade = 5, level = "NUTS-3", Year = 2023,
                   WLE = FALSE, data = example_Invalsi23_prov)

Util_Invalsi_filter(subj = c("Italian", "Mathematics"), grade = 5, level = "NUTS-3", Year = 2023,
                    WLE = TRUE, data = example_Invalsi23_prov)

Invalsi23_high <- Util_Invalsi_filter(subj = "Italian", grade = c(10,13), level = "NUTS-3",
                                      Year = 2023, data = example_Invalsi23_prov)


 summary(Invalsi23_high)


[Package SchoolDataIT version 0.2.0 Index]