Data Cascading Functions
cascade_to_nuts2_and_compute.RdFunctions for cascading data from NUTS0/NUTS1 to NUTS2 level.
cascade_to_nuts2_and_compute also computes derived indicators (DA, rLOS).
cascade_to_nuts2_light is a simpler version for pre-computed scores.
balance_panel ensures all geo-year combinations exist.
Arguments
- data
Dataframe with 'geo', 'year', and variable columns
- vars
Character vector of variable names to cascade
- years
Integer vector of years to include
- nuts2_ref
Reference table from get_nuts2_ref()
- nuts_year
Integer year for NUTS classification
- agg
Aggregation function for duplicates
- fill_direction
Direction for filling ("downup", "down", "up")