Open joshgilbert1994 opened 1 week ago
@ben-domingue @KingArthur0205
processed data: K-PCQ_Huh_2022.csv
code:
library(tidyr)
library(dplyr)
df <- read.table("Suppl_2_response_data_358.tab", header=TRUE, sep="\t")
df <- df %>% select(Crav1:Crav12)
df$id <- seq(1, nrow(df))
df <- df %>%
pivot_longer(c(Crav1:Crav12),
names_to = "item",
values_to = "resp") %>%
filter(!is.na(resp))
write.csv(df, "K-PCQ_Huh_2022.csv", row.names=FALSE)
@saviranadela
looking at table 1, i think we need to cut the resp=0
options?
https://pmc.ncbi.nlm.nih.gov/articles/PMC8256136/
Public domain
https://dataverse.harvard.edu/dataset.xhtml?persistentId=doi:10.7910/DVN/SHCUI4