Standardize the compensation table data frame (from 990 form, Part VII, Table 01)
standardize_df.Rdstandardize_df returns a processed data frame with renamed column titles
and cleaned up fields from the raw table extracted from PVII T01 build. Also,
this function removes duplicated lines if present. Both the input and output
are data frames. Ultimately this function provides takes in raw data and
returns a data frame with understandable information about DTK individuals.
Usage
standardize_df(
df,
EIN = "EIN2",
OBJECTID = "OBJECTID",
title = "F9_07_COMP_DTK_TITLE",
form.type = "RETURN_TYPE",
ave.hours = "F9_07_COMP_DTK_AVE_HOUR_WEEK",
ave.hours.rltd = "F9_07_COMP_DTK_AVE_HOUR_WEEK_RL",
comp.base = "F9_07_COMP_DTK_COMP_ORG",
comp.benefits = "F9_07_COMP_DTK_EMPL_BEN",
comp.related = "F9_07_COMP_DTK_COMP_RLTD",
comp.other = "F9_07_COMP_DTK_COMP_OTH",
trustee.ind = "F9_07_COMP_DTK_POS_INDIV_TRUST_X",
trustee.inst = "F9_07_COMP_DTK_POS_INST_TRUST_X",
officer = "F9_07_COMP_DTK_POS_OFF_X",
key.employee = "F9_07_COMP_DTK_POS_KEY_EMPL_X",
high.comp.ind = "F9_07_COMP_DTK_POS_HIGH_COMP_X",
former = "F9_07_COMP_DTK_POS_FORMER_X",
name = "F9_07_COMP_DTK_NAME_PERS",
biz1 = "F9_07_COMP_DTK_NAME_ORG_L1",
biz2 = "F9_07_COMP_DTK_NAME_ORG_L2"
)Arguments
- df
A Part VII compensation data frame.
- EIN
Column name for the organization EIN.
- OBJECTID
Column name for the filing object id.
- title
Name of the title column to operate on.
- form.type
Column name for the 990 return type (e.g. "990", "990EZ").
- ave.hours
Column name for average weekly hours.
- ave.hours.rltd
Column name for average weekly hours at related organizations.
- comp.base
Column name for base compensation from the organization.
- comp.benefits
Column name for benefits compensation.
Column name for compensation from related organizations.
- comp.other
Column name for other compensation.
- trustee.ind
Column name for the individual-trustee checkbox.
- trustee.inst
Column name for the institutional-trustee checkbox.
- officer
Name of the officer-flag column.
- key.employee
Column name for the key-employee checkbox.
- high.comp.ind
Column name for the highly-compensated checkbox.
- former
Column name for the former-officer checkbox.
- name
Column name for the person's name.
- biz1
Column name for the organization name, line 1.
- biz2
Column name for the organization name, line 2.