rescale_trust: Rescale trust institutions question

Description Usage Arguments Examples

Description

Rescale Eurobarometer trust in institutions variable with two levels, "Tend to trust" and "Tend not to trust". This is a wrapper function around the rescale_categories function.

Usage

1
2
3
rescale_trust(column, from = c("Tend to trust", "Tend not to trust"),
  to = c(1, 0), na_labels = "default", exact_from = TRUE,
  return_class = "numeric", messages = FALSE)

Arguments

column

A column from a survey data frame where trust in an institution is recorded.

from

Defaults to c("Tend to trust", "Tend not to trust").

to

Defaults to c(1,0). If return_class = "character" or return_class = "factor" is selected it returns the abbreviated category names c("trust", "distrust").

na_labels

Defaults to "default".

exact_from

Deafults to TRUE. If FALSE you can use the partial matching, but beware that in this case, "twenty" will be replaced by

return_class

Default is "numeric", alternatives "character" or "factor".

messages

Defaults to FALSE. Hides missing factor value messages.

Examples

1
2
3
4
5
6
rescale_direction (column =
   c("Things are going in the right direction",
     "Things are going in the wrong direction",
     "Neither one nor the other (SPONTANEOUS)",
     "DK"),
     na_labels = "DK")

antaldaniel/surveyreader documentation built on May 16, 2019, 2:29 a.m.