make_combo: Make combo

View source: R/behavioural_obs.R

make_comboR Documentation

Make combo

Description

Make combo

Usage

make_combo(x, UL = "UL", LL = "LL", UR = "UR", LR = "LR", short)

Arguments

x

a data.table

UL

character vector, Upper Left

LL

character vector, Lower Left

UR

character vector, Upper Right

LR

character vector,Lower Right

only_use

character vector UL, LL, UR or LR. if not missing will use this one only

Examples

require(beR)
x = fread(
"UL; LL; UR; LR
M ; DG ; R,DG,R
M ; DG ; Y,R,DB
M ; DG ; DB,DG,DG
M ; DG ; Y,DB,R
M ; DG ; DB,R,O
M ; DG ; Y,DG,DG
M ; DG ; R,Y,O    
M ; DG ; NA    
"
, sep = ";" )
make_combo(x)
setnames(x, "LR", "LoR")
make_combo(x, LR = 'LoR')
make_combo(x, short = "UR")


mpio-be/beR documentation built on Dec. 17, 2024, 1:40 p.m.