This function returns a smaller set of summary data from the comparison_table for the focal institution and its comparisons.

sg_return_college_summary(
  institution_id,
  categories = c("Basic"),
  focal_only = FALSE
)

Arguments

institution_id

The UNITID for the institution

categories

The vector of categories to include. See table(categories_and_fields$Category) for options with number of fields within. Default is "Basic".

focal_only

If TRUE, only returns data for the focal institution. Default is FALSE.

Value

A data.frame with summary data for the focal institution and its comparisons

Details

The comparison_table data structure has many, many fields (1038 columns in total). This function pulls out a smaller set of data useful for making arguments about shared governance: budgets, enrollments, faculty counts, and so on. By default it will do it for the focal college and its comparisons.

Examples

id <- sg_find_college("University of Massachusetts, Amherst", verbose=FALSE)
summary_data <- sg_return_college_summary(id, categories=c("Basic", "Institution_Finances", "Enrollment"), focal_only=TRUE)
print(summary_data[, c("Year", "Undergrad full time", "Revenue minus expenses")])
#>       Year Undergrad full time Revenue minus expenses
#> 1163  2024                <NA>                     NA
#> 5145  2023               22537              146061738
#> 9184  2022               22920              113112772
#> 13258 2021               22539               17224696
#> 17321 2020               22212                8015674
#> 21423 2019               22491               42167798
#> 25615 2018               21784               45584000
#> 30005 2017               21577              103812000
#> 34528 2016               21460               77762000
#> 39145 2015               21098               71494000
#> 43937 2014               20684              112829000