# data file needs to be in the same directory as the R-Markdown-Script
library(readr)
tdata <- read_delim("tdata_final.txt",
delim = "\t", escape_double = FALSE,
trim_ws = TRUE)
## Rows: 122 Columns: 12
## ── Column specification ────────────────────────────────────────────────────────
## Delimiter: "\t"
## chr (7): subj_code, desktop_conf, attent_conf, Cond_sum, explanation, gender...
## dbl (5): condition, instr_tests, Rating_CC, Rating_SE, age
##
## ℹ Use `spec()` to retrieve the full column specification for this data.
## ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
# demographics
min(tdata$age)
## [1] 19
max(tdata$age)
## [1] 76
mean(tdata$age)
## [1] 38.7377
sd(tdata$age)
## [1] 12.82676
# 1 = male, 2 = female, 3 = other
table(tdata$gender)
##
## 1: male 2: female
## 46 76
1 = male, 2 = female, 3 = non-binary
## Warning: `guides(<scale> = FALSE)` is deprecated. Please use `guides(<scale> =
## "none")` instead.
## Warning: `fun.y` is deprecated. Use `fun` instead.
## `fun.y` is deprecated. Use `fun` instead.
## `fun.y` is deprecated. Use `fun` instead.
binary <- subset(tdata_long, Cond_sum == "binary_raidal" | Cond_sum == "binary_channel")
binary$Cond_sum <- factor(binary$Cond_sum, levels = c("binary_channel","binary_raidal"), labels = c("binary & channel", "binary & radial"))
continuous <- subset(tdata_long, Cond_sum != "binary_raidal" & Cond_sum != "binary_channel")
continuous$Cond_sum <- factor(continuous$Cond_sum,
levels = c("cont_channel_limited", "cont_channel_ulimited", "cont_radial_limited", "cont_radial_unlimited"),
labels = c("channel & limited", "channel & unlimited", "radial & limited", "radial & unlimited"))
## Warning: `guides(<scale> = FALSE)` is deprecated. Please use `guides(<scale> =
## "none")` instead.
## Warning: `fun.y` is deprecated. Use `fun` instead.
## `fun.y` is deprecated. Use `fun` instead.
## `fun.y` is deprecated. Use `fun` instead.