#' household income
#'
#' @description This function calculates the household income from the applicants
#' @param df The name of the dataframe you want to manipulate
#' @return datatframe, tibble
#' @keywords household income
#' @import data.table
#' @export
#' @examples tidyHouseholdIncome(df = df)
tidy.household.income <- function(df) {
df <- df %>%
data.table::as.data.table() %>%
.[, haushaltseinkommen := sum(einkommen.as1, einkommen.as2, na.rm = TRUE),
by = vorgangsnummer]
return(df)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.