jeudi 4 février 2021

Select random 50% of sample, but only 1 person per couple in SPSS

I'm trying to run an analysis on data with heterosexual couples. I need to select a random 50% of women and a random 50% of men they are not married to. I know how to filter out a random percentage of the total sample, but not how to ensure that only one person per household is selected.

My data look like this:

couple person gender Q1 Q2 Q3 Q4 Q5

1 1 0 3.5 4.2 2.3 3.3 4.3

1 2 1 3.2 2.5 2.1 3.7 5.6

2 1 1 3.7 2.6 3.3 4.2 5.1

2 2 0 3.0 3.5 2.1 3.6 5.4

It's in long format, so each row represents a person and there are two people per couple.




Aucun commentaire:

Enregistrer un commentaire