Skip to content

Commit

Permalink
Remove year column. Fix #103
Browse files Browse the repository at this point in the history
  • Loading branch information
usr110 committed May 31, 2022
1 parent 0634be6 commit 7006e4a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/set_injury_contingency.R
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ set_injury_contingency <- function(injuries){
}
injury_table <- list()
for(type in c(injury_table_types)){
keep_names <- names(injury_list[[type]])%in%c('year','cas_mode','strike_mode','age_cat','cas_gender')
keep_names <- names(injury_list[[type]])%in%c('cas_mode','strike_mode','age_cat','cas_gender')
# summarise list of injuries by group
setDT(injury_list[[type]])
injury_summary <- as.data.frame(injury_list[[type]][,.(count=.N,weight=mean(weight)),by=c(names(injury_list[[type]])[keep_names])])
Expand Down

0 comments on commit 7006e4a

Please sign in to comment.