How can a survey sample be weighted (by 4 demographic variables) so that it is a representative sample of the population? (As can be done in software)
Hi @Yos_6918849 and welcome to the forum.
Can you provide some more detail about what you’re trying to do? Maybe upload some dataset or workflow in progress?
This might be a case where a bit of scripting in a Python Script node is your best bet, but hard to tell without more info.
I have an Excel file containing data from a public opinion survey on political issues, including answers to a question about voting intentions for one of the 11 parties running in the elections (a categorical variable, used as the dependent variable/target variable). The independent variables include 8 interval variables and 6 more categorical variables. In addition, there are 4 more categorical demographic variables (age group, gender, religion, and sector affiliation). The file has an additional column that is actually the weighting coefficient of the sample (the weighting coefficients for each observation were performed using SPSS software). After reading the Excel file to the desktop in Knime, I would like to know how the sample can be weighted (based on the weighting coefficient attached as a separate column in the read file), including separate reference to the categorical and interval variables?