filter_le: Filtering Life Events by Age and Influence

Description Usage Arguments Value

Description

filter_le filters life events by a specified age and influence at time of interview. By default life events occuring at the same age year as the specified age filter are kept. Life events passing the filteres are indicated by 1 and are otherwise 0.

Usage

1
2
3
4
filter_le(data, min.age.filter = F, min.age = NULL,
  include.first.year = F, max.age.filter = F, max.age = NULL,
  include.last.year = F, influence.filter = F, min.influence = 1,
  reliable = T)

Arguments

data

A data frame containing the life events data

min.age.filter

A logical. If min.age.filter = T, life events will be filtered according to the min.age and include.first.year settings. Missing age information will set life event to missing.

min.age

A string. Name of the column with the minimum allowable age. Since the age at which a life event happened is only available at whole years, this can also include events, which happened before the allowable age, if include.first.year = T.

include.first.year

A logical. If TRUE, life events occuring at the same age as "min.age" are kept. Thus some events might have happened before "max.age". If FALSE, life events occuring at the same age will be set as not having occured. Default is FALSE.

max.age.filter

A logical. If max.age.filter = T, life events will be filtered according to the max.age and include.last.year settings. Missing age information will set life event to missing.

max.age

A string. Name of the column with the maximum allowable age. Since the age at which a life event happened is only available at whole years, this can also include events, which happened after the allowable age, if include.last.year = T.

include.last.year

A logical. If TRUE, life events occuring at the same age as "max.age" are kept. Thus some events might have happened after "max.age". If FALSE, life events occuring at the same age will be set as not having occured. Default is FALSE.

influence.filter

A logical. If influence.filter = T, life events will be filtered according to the min.influence setting. Missing influence information will set life events to missing.

min.influence

A numeric value. The minimum amount of influence at the time of interview.

  1. 'no influence / geen'

  2. 'a little influence / een beetje'

  3. 'moderate influence / tamelijk veel'

  4. 'a lot of influence / heel veel'

reliable

A logical. Indicates whether life events should be omitted, when they were judged to be unreliable, e.g. when language difficulties were noted during the interview. reliable = T omits unreliable life events, reliable = F keeps them. Missing reliability information is assumed to be reliable.

Value

A matrix containing information whether life events occured (1) or not (0).


aneumann-science/LifeEvents documentation built on May 10, 2019, 11:46 a.m.