knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)
options(rmarkdown.html_vignette.check_title = FALSE)
frag_path <- here::here("man", "fragments", "zygocity")
paths <- list.files(frag_path, "Rmd", full.names = TRUE)
names(paths) <- gsub("\\.Rmd", "", basename(paths))
paths <- as.list(paths)

Background


Scoring



Equation


Data requirements


Use the zygo functions

Currently undocumented...

library(questionnaires)
library(dplyr)
zygo <- tibble(
  id = 1:10,
  twinpair = rep(1:5, each = 2),
  drop = c(1, 2, 3, NA, 2, 2, 1, 1, NA, 2),
  stranger = c(1, 2, 4, NA, 2, 3, 3, 1, NA, 2),
  dexterity = c(1, 1, 3, NA, 2, 2, 1, 2, NA, 1),
  voice = c(2, 2, 3, NA, 2, 2, 1, 1, NA, 1),
  eye = c(2, 2, 2, NA, 2, 2, 1, 1, NA, 2),
  belief = c(1, 1, 2, NA, 2, 2, 1, 1, NA, 2)
)

zygo_compute(zygo, 
             twin_col = twinpair, 
             cols = 3:6, 
             recode = FALSE)

References




LCBC-UiO/Questionnaires documentation built on July 18, 2023, 6:45 p.m.