dss-hmi / suicide-prevention-2019

Projects evaluates change in suicide morbidity and mortality rates among youth (10-24) in relationship to the GLS suicide prevention program in selected Florida counties.
GNU General Public License v2.0
0 stars 1 forks source link

Filling in the implied values (fixing Excel) #6

Open andkov opened 5 years ago

andkov commented 5 years ago

4 imports data from a Population Estimate query editor. It is given as a Microsoft Excel 97-2003 file. However, when opening on a Windows 10 system the prompt did not identified the file as a valid Excel file, but opened nonetheless. We saved the file as ".xlsx" and fed it to the greeter ./manipulation/0-greeter-population.R.

The Population Estimate Query structured results as Excel spreadsheet image

When imported into RStudio, the grouped cells in the Excel spreadsheet become NA in the imported dataframe: image

TODO

Using a representative data frame (link) develop a solution to fill in the NA values.

andkov commented 5 years ago

Possible logic of the solution:

Tried this solution, but it solves only a single row.

Jodh commented 5 years ago

Started a merge request which solves the issue, but the code could be better written.