cr_extract(dataset, worksheet, row, column, newname = "newvar")rpt_rec_number,
used to merge data, and a column of the data requested, which is renamed if
desired.
It does automatically recode rows and columns into all possible permutations (ie '500', '0500', '00500', 500) when subsetting, since different cost reports use different schema.
This function *does not* throw an error if the parameters yield an empty dataset at any point. It only gives warnings. This is because oftentimes the parameters are valid but the data is missing in the source material, due to CMS scrubbing of what data gets published.
alpha_data <- hospiceALPHA
hospice_name <- cr_extract(alpha_data, "S100000", 100, 100, "name")
Run the code above in your browser using DataLab