1,264 questions
0
votes
0
answers
31
views
Qualtrics branching logic doesn't move from loop and merge block to final block
In Qualtrics, I have a survey with 3 blocks for collecting field vehicle data:
Block 1: Starting info (day, time, etc.).
Block 2: Loops vehicle questions based on a question at the start of the block: ...
1
vote
1
answer
125
views
How can I dynamically create a Likert-scale matrix from user-defined input?
For a questionnaire in LimeSurvey v6 I need to implement a two-part question.
In question 1 the respondent should be able to enter the name of organizations they work with, one per row. Ideally the ...
0
votes
0
answers
58
views
Survey Js, Survey Creator custom class - panel model
I'm working in SurveyJS, specifically in survey-creator. I want to create a custom class that extends panelmodel, but when trying to add it to survey-creator, it gives the error Uncaught (in promise) ...
3
votes
1
answer
83
views
R. Contrasting predicted means in R survey package with splines
In the R "survey" package the svyglm() function can be used with svypredmeans() and svycontrast() in order to compare predictive marginal means for a generalised linear model. This works ...
1
vote
1
answer
93
views
AME with Survey weights
I'm trying to calculate average marginal effects (AMEs) from a logistic regression model estimated with svyglm from the survey package.
I am using the design from a specialised package developed to ...
0
votes
1
answer
39
views
Missing Person Replicate Weight Variable Error in tidycensus
I'm analyzing the demographic characteristics of nurse practitioners in the US using the 2023 ACS survey and tidycensus.
I've downloaded the data using this code:
pums_2023 = get_pums(
variables = c(...
0
votes
0
answers
37
views
How to create a table of survey-weighted means by cohort using svy: mean
I am working with survey data and want to compute the survey-weighted mean of age at sexual initiation by year of birth (yob) cohort, along with standard errors and 95% confidence intervals.
I've ...
0
votes
1
answer
96
views
Qualtrics - error in getting values from question
I am attempting to write a survey which will provide experimental vignettes to participants based on previous ratings of political parties. Obviously, this means that I'll need to pipe results from ...
0
votes
0
answers
49
views
Making Odds Ratio Table with texreg using svyglm
I am wondering how to make an odds ratio table using svyglm from the survey
package and texreg. Here is my attempt with some sample data:
# Load necessary packages
library(survey)
library(texreg)
# ...
-1
votes
1
answer
72
views
survey-react-ui onUploadFiles not triggering on choose file button file picked
I am using survey-react-ui version 1.12.27, all other events are triggering but onUploadFiles event is not triggering.
When i select file using "choose file" button event does not trigger. ...
-2
votes
1
answer
46
views
Please help me make cross tabs with survey data (basic) [closed]
I work with survey data which I get from a contractor (it's weighted). But I sometimes need different cross tabs from those they provide me. I don't currently have any budget for any software to do it,...
0
votes
1
answer
79
views
gtsummary stopped working on regression objects [closed]
Problem: This has just recently started happening, but all of a sudden I cannot use any functions from the gtsummary package. I've tried removing it and reinstalling, both the CRAN distro and the dev ...
2
votes
2
answers
135
views
R Function to replace all instances of "f" in a factored variable?
I'm new to R - so I'm sorry if this has been asked but I've not found a solution online. I have a data set of survey responses related to gender and sex that were typed in by 350 participants. Many of ...
0
votes
0
answers
60
views
Odoo 16 advanced grouping in view
I'm trying to get extract information from Odoo surveys from the "Detailed answers" pivot view (I had to enable the pivot view myself since the detailed views only has tree and kanban views ...
1
vote
0
answers
125
views
add_ci() for row percentages in gtsummary tbl_svysummary() function
I was wondering if there is a way to add confidence intervals for the row percentages created using gtsummary.
Example code:
# Load required packages
library(survey)
library(gtsummary)
library(dplyr)
...
2
votes
1
answer
158
views
Trying to understand differences in weighted logistic regression outputs between Statsmodels and R's survey & srvyr packages
I have a fictional weighted survey dataset that contains information about respondents' car colors and their response to the question "I enjoy driving fast." I would like to perform a ...
0
votes
1
answer
58
views
In Qualtrics, what can I do to make my with javasectipt embedded HTML text exactly the same as the default text?
I try to have a table visible for multiple questions on multiple qualtrics pages one after the other. I followed guidelines here: https://community.qualtrics.com/custom-code-12/pin-instructions-to-top-...
1
vote
1
answer
69
views
Calculate svymean for variable within user-defined function called by mutate(), across(), with variable name as function parameter
My goal is to take a dataframe that contains individual level data of many variables and apply a user defined function to return those variables' survey-adjusted weighted means and create new columns ...
0
votes
0
answers
43
views
Diverging stacked bar chart for 5-point Likert data with N/A values
Aiming to create a Likert stacked bar plot that includes responses that were "Not applicable or N/A" on the side in an adjoining plot or in the border of figure to provide context. Each row ...
1
vote
0
answers
81
views
Larger-than-memory Survey Analysis with R+Arrow
I'm currently trying to analyze data from the National Inpatient Sample (NIS). When combining multiple years worth of data, my files are just over 8 GB after processing/selecting relevant columns. I ...
1
vote
1
answer
67
views
How can I get my R formula to correctly parse a true/false statement as one of its arguments? [closed]
I have a fictional weighted survey dataset that shows how responses to the question "I enjoy driving fast" vary by respondents' car colors. Here's a sample of the original dataset:
Car_Color ...
1
vote
1
answer
69
views
NA values when running summary statistics for NSCH data in R using mitools and survey packages
I am working with NSCH data for the first time in R. I found the following resource, which has been enormously helpful (thank you!).
https://github.com/ajdamico/asdfree/blob/master/nsch.Rmd
I followed ...
4
votes
2
answers
212
views
R survey data add weights
I have survey data with weights already assigned. Here is a toy sample.
If I don't weight the data, it will not be an accurate representation of the population. Is there a simple way to factor in ...
0
votes
2
answers
107
views
Issue with MIcombine when using svyciprop for estimating CIs. Multiple Imputation and Complex Survey
I am working with multiply imputed complex survey data and trying to estimate CIs for a proportion using the Thomas Lumley's survey and mitools package, in particular svyciprop() function with beta ...
0
votes
1
answer
98
views
How to save survey designed dataset for other analysis (preferred R)
Is there any way to save weighted survey with strata and fpc as dataframe? For example, here is the simple dataframe:
Data <- data.frame(
X =c(1,4,6,4,1,7,3,2,2),
Y = c(6,5,9,9,43,65,45,67,90),
...
0
votes
1
answer
103
views
How to include missing values in svytable in R to match Stata’s tab command?
Sure, here's a Stack Overflow question you could use:
I'm trying to replicate a Stata command in R using the survey package but I'm not getting the same results. In Stata, I use the following command ...
1
vote
1
answer
64
views
The use of I() in svyciprop() in the Survey package
I want to estimate various proportions and their confidence intervals using the Survey package in R, using the svyciprop() function, like this
data(api)
dclus1<-svydesign(id=~dnum, fpc=~fpc, data=...
1
vote
1
answer
82
views
R becomes unresponsive when bootstrapping replicate survey designs
I have a dataset with survey data from about 40,000 respondents (and about 600 variables), and I want to calculate statistics (mean, median, etc.) and their variance, including among subgroups like ...
0
votes
1
answer
101
views
getting decimal places in confidence intervals for survey analysis
I am using the below R code but cannot figure our how to get the confidence intervals with two decimal places:
library(gtsummary)
survey::svydesign(id = ~PSU, weights = ~WT_analysis, strata = ~...
0
votes
1
answer
164
views
How to make a graph for average adjusted predictions at the mean using the svyglm
I am trying to figure out what is the most accurate way to plot average adjusted predictions at the mean using the svyglm function from the survey package. I have used two approaches so far. One using ...
0
votes
0
answers
33
views
Need help for using davies.test in segmented package for segmented.default
I am having an issue with the segmented package in R. The issue is when I use the davies.test and segmented.default. The code I am working with is as follows:
library(segmented)
library(survey)
data(...
0
votes
1
answer
55
views
Trying to analyze the results from an open-answer question from a survey
I am currently learning how to perform data analysis in R Studio and I am using an SPSS database as an example. Currently I am having problems with the results of an open answer question where people ...
1
vote
1
answer
161
views
How to calculate medians svyquantiles using svyby from survey package?
I am reading the book Complex Survey and trying to follow the book codes, perhaps because the book is a little old now the codes are not working as intended, I don't know for sure.
I am trying to ...
3
votes
2
answers
61
views
svyby - how to call in different variables for by formula in a function?
I would like to pass an assigned variable to a function that would be used as part of a formula in the svyby function from the survey package. My reason for wanting to do this is I want to get ...
0
votes
1
answer
53
views
Points Doubling Issue in Simple SwiftUI Survey App
I'm building a survey app as a part of my thesis. A part of this application is a 'point system' that gives the user feedback on how the options they select impact factors in the design process with ...
2
votes
1
answer
397
views
Populate SurveyJS file upload with remote data
I'm using SurveyJS to create a multi step form for users to check their existing profile. The survey is pre-populated with values from an API, so the user can check those and submit changes. Therefore,...
0
votes
0
answers
45
views
LIme Survery Multiple choice in table format
enter image description hereCould anyone provide guidance on how to create a table format for multiple-choice questions in LimeSurvey, similar to the one shown in the image? I would greatly appreciate ...
1
vote
1
answer
100
views
Import a surveyJS custom theme in svelte code
Morning,
Since yesterday, I have been trying to add a custom theme by following the information given on the surveyJS site.
I'm developing a site with svelte, I managed to import the form, but it's ...
0
votes
2
answers
115
views
How to iterate object in svytable while dynamically subsetting survey design
I have survey data I'm creating contingency tables for. I have 3 specific variables I want to both loop over and subset my survey object with the factor levels of those 3 specific variables to get the ...
1
vote
1
answer
121
views
Error in kruskal_test (coin) with Weighted Data: “Invalid Object Class 'IndependenceProblem’”
I am trying to perform a weighted Kruskal-Wallis test for each group in a dataset, but I keep encountering the following error:
Error in kruskal_test: Error in validObject(.Object): invalid class “...
1
vote
3
answers
129
views
How to code survey question results with randomized order choices?
I'm cleaning data from a qualtrics survey that includes a few questions where the answer choices were randomized (e.g. you rate five tv shows, and the show order is randomized for each respondent). ...
1
vote
0
answers
149
views
How to get survey and gtsummary to report ALL levels of factor variable
The 3rd level is not appearing in the table. I would like all 4 factor levels of v1.fac to appear, including "Green". Similar to missing = 'always' is there a way? My almost complete table ...
1
vote
1
answer
69
views
Mystery bug in sampling for loop in R
I am trying to understand what is causing this bug in my R code and I feel like R is gaslighting me.
The sample() function seems to change depending on how I assign it?
Anyways, here is the MRE:
#...
-2
votes
1
answer
81
views
Is there a function in REDCap
I am conducting a survey on REDCap that is anonymous. We want to make a "giftcard draw" for those who have answered the survey. However, in order to be in the drawing, they have to enter ...
1
vote
2
answers
118
views
How to match the student to his own teacher?
There are 3 classes, each with 10 students. Each class has their own homeroom teacher. When a student submits the form and chooses his homeroom teacher's identity, I have to make sure that he chooses ...
0
votes
1
answer
206
views
How to re-order the responses when plotting Likert scale data in R?
I have survey data that I am trying to plot in R but the issue is that the responses appear in alphabetical order as seen in the graph below:
I would like the responses to be in the order "...
-1
votes
1
answer
52
views
R code - Make a plot for survey responses
I am trying to make some barplots with my data but I keep hitting some walls. If someone on here could help that'd be great
I wanted to create barplots with side by side comparison of pre vs post ...
-1
votes
2
answers
57
views
How to compute new variables out of items using rowMeans function in a loop function (big data set)?
I need your help because I have a big data set about illnesses (wide format). So I have 54 different illnesses, each having a block of 18 questions (data is nested in illnesses and participants).
As I ...
-1
votes
1
answer
51
views
How to convert wide-data to long-data format for big dataset? [closed]
I am conducting a cross-sectional online study about 54 illnesses, and have 10 variables/columns for participants' background information, then participants were randomly assigned to a set of 9 ...
1
vote
1
answer
152
views
How to get expected %ages with CIs for different possible responses from svy_vglm in svyVGAM?
I am looking to calculate survey-weighted percentages for categorical outcomes using the svy_vglm function of svyVGAM. For example, if the categorical variable could be A, B, or C, I simply want to ...