answer_as_binary: Yes/No answer to binary

View source: R/answer_as_binary.R

answer_as_binaryR Documentation

Yes/No answer to binary

Description

This function allows you to convert multiple yes/no answers in binary format

Usage

answer_as_binary(df, vars)

Arguments

df

The dataframe containing the information.

vars

a variable (or vector of variables) quoted that you want to change to binary.

Value

The binary answers, changing "no" or "none" to 0 and "yes" to 1.

Examples

answer_as_binary(df, "tenencia_bici")

samesag/emu documentation built on Aug. 22, 2023, 3:19 p.m.