Power and Sample Size Simulation: EAMMi2
Christopher L. Aberson
2024-11-10
mcfall_vignette.Rmd
Project/Data Title:
Emerging Adulthood Measured at Multiple Institutions 2: The Next Generation (EAMMi2)
Data provided by: Joe McFall
Project/Data Description:
Collaborators from 32 academic institutions primarily in the United States collected data from emerging adults (Nraw = 4220, Nprocessed = 3134). Participants completed self-report measures assessing markers of adulthood, IDEA inventory of dimensions of emerging adulthood, subjective well-being, mindfulness, belonging, self-efficacy, disability identity, somatic health, perceived stress, perceived social support, social media use, political affiliation, beliefs about the American dream, interpersonal transgressions, narcissism, interpersonal exploitativeness, beliefs about marriage, and demographics.
Methods Description:
Project organizers recruited contributors through social media (Facebook & Twitter) and listserv invitations (Society of Personality and Social Psychology, Society of Teaching Psychology).
Data Location:
EAMMi2<- import("data/mcfall_data.sav.zip") %>%
select(starts_with("moa1#"), starts_with("moa2#"))
str(EAMMi2)
#> 'data.frame': 3134 obs. of 40 variables:
#> $ moa1#1_1 : num 3 4 4 4 4 4 3 4 4 1 ...
#> ..- attr(*, "label")= chr "imp_financialindependence"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_2 : num 4 4 4 3 2 3 2 3 3 2 ...
#> ..- attr(*, "label")= chr "imp_nolongerhom"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_3 : num 3 4 4 4 4 4 1 2 4 1 ...
#> ..- attr(*, "label")= chr "imp_finishededucation"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_4 : num 2 1 4 3 3 NA 1 1 4 1 ...
#> ..- attr(*, "label")= chr "imp_married"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_5 : num 3 1 4 3 3 NA 1 1 4 1 ...
#> ..- attr(*, "label")= chr "imp_havechild"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_6 : num 4 3 3 4 3 4 1 2 4 1 ...
#> ..- attr(*, "label")= chr "imp_settledcareer"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_7 : num 4 2 1 4 4 4 1 1 3 4 ...
#> ..- attr(*, "label")= chr "imp_avoiddrunk"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_8 : num 4 3 4 4 4 4 4 1 3 4 ...
#> ..- attr(*, "label")= chr "imp_avoiddrugs"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_9 : num 4 4 4 4 2 4 4 1 2 4 ...
#> ..- attr(*, "label")= chr "imp_usecontraception"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#1_10: num 2 2 4 3 3 3 1 1 3 1 ...
#> ..- attr(*, "label")= chr "imp_committedlongterm"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa1#2_1 : num 1 2 2 3 2 1 2 1 2 3 ...
#> ..- attr(*, "label")= chr "ach_financialindependence"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa1#2_2 : num 3 1 3 1 2 3 2 2 1 3 ...
#> ..- attr(*, "label")= chr "ach_nolongerhome"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa1#2_3 : num 1 2 2 2 1 1 2 1 1 3 ...
#> ..- attr(*, "label")= chr "ach_finishededucation"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa1#2_4 : num 2 1 3 1 1 NA 2 1 1 3 ...
#> ..- attr(*, "label")= chr "ach_married"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa1#2_5 : num 3 1 3 1 1 NA 2 1 1 2 ...
#> ..- attr(*, "label")= chr "ach_havechild"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa1#2_6 : num 2 2 1 1 1 1 2 1 1 3 ...
#> ..- attr(*, "label")= chr "ach_settledcareer"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa1#2_7 : num 3 2 1 3 2 3 2 1 1 3 ...
#> ..- attr(*, "label")= chr "ach_avoiddrunk"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa1#2_8 : num 3 3 3 3 3 3 2 1 1 3 ...
#> ..- attr(*, "label")= chr "ach_avoiddrugs"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa1#2_9 : num 3 3 3 3 3 3 2 3 3 3 ...
#> ..- attr(*, "label")= chr "ach_usecontraception"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa1#2_10: num 3 1 3 1 1 1 2 2 1 2 ...
#> ..- attr(*, "label")= chr "ach_committedlongterm"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "achieved"
#> $ moa2#1_1 : num 4 4 3 4 4 3 1 4 4 4 ...
#> ..- attr(*, "label")= chr "imp_indepedentdecisions"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_2 : num 4 4 4 4 4 3 1 3 4 4 ...
#> ..- attr(*, "label")= chr "imp_supportfamily"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_3 : num 3 3 4 3 4 1 1 2 4 4 ...
#> ..- attr(*, "label")= chr "imp_carechildren"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_4 : num 4 4 4 4 3 4 1 4 3 4 ...
#> ..- attr(*, "label")= chr "imp_acceptresponsibility"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_5 : num 4 3 4 3 3 4 1 3 4 2 ...
#> ..- attr(*, "label")= chr "imp_employfulltime"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_6 : num 4 4 4 4 4 4 1 2 3 4 ...
#> ..- attr(*, "label")= chr "imp_avoiddrunkdriving"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_7 : num 3 4 4 3 2 2 1 3 3 4 ...
#> ..- attr(*, "label")= chr "imp_parentasequal"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_8 : num 4 3 4 4 4 4 1 4 4 4 ...
#> ..- attr(*, "label")= chr "imp_emotionalcontrol"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_9 : num 3 3 4 4 3 4 1 3 4 2 ...
#> ..- attr(*, "label")= chr "imp_considerothers"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#1_10: num 2 4 2 3 4 1 1 4 4 1 ...
#> ..- attr(*, "label")= chr "imp_supportparentsfinance"
#> ..- attr(*, "format.spss")= chr "F12.0"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:2] 1 4
#> .. ..- attr(*, "names")= chr [1:2] "not important" "important"
#> $ moa2#2_1 : num 3 3 2 3 2 3 2 2 3 3 ...
#> ..- attr(*, "label")= chr "achi_independentdecisions"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_2 : num 2 1 2 2 1 1 2 1 1 2 ...
#> ..- attr(*, "label")= chr "ach_supportfamily"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_3 : num 3 1 3 2 2 1 2 1 3 3 ...
#> ..- attr(*, "label")= chr "ach_carechildren"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_4 : num 2 3 2 3 3 3 2 2 2 3 ...
#> ..- attr(*, "label")= chr "ach_acceptresponsibility"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_5 : num 3 1 1 2 2 3 2 1 3 3 ...
#> ..- attr(*, "label")= chr "ach_employfulltime"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_6 : num 3 3 3 3 2 3 2 3 2 3 ...
#> ..- attr(*, "label")= chr "ach_avoiddrunkdriving"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_7 : num 3 3 3 2 2 1 2 1 3 2 ...
#> ..- attr(*, "label")= chr "ach_parentasequal"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_8 : num 2 3 2 3 2 1 2 2 3 2 ...
#> ..- attr(*, "label")= chr "ach_emotionalcontrol"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_9 : num 2 3 2 3 3 3 2 2 3 2 ...
#> ..- attr(*, "label")= chr "ach_considerothers"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
#> $ moa2#2_10: num 1 1 1 2 1 1 2 1 3 3 ...
#> ..- attr(*, "label")= chr "ach_supportparentsfinances"
#> ..- attr(*, "format.spss")= chr "F12.1"
#> ..- attr(*, "display_width")= int 12
#> ..- attr(*, "labels")= Named num [1:3] 1 2 3
#> .. ..- attr(*, "names")= chr [1:3] "no" "somewhat" "yes"
Dataset Citation:
Grahe, J. E., Chalk, H. M., Cramblet Alvarez, L. D., Faas, C., Hermann, A., McFall, J. P., & Molyneux, K. (2018, January 10). EAMMi2 Public Data. Retrieved from: https://osf.io/x7mp2/.
Geographic Description - City/State/Country of Participants:
Mostly United States but any English speaker could complete.
Column Metadata:
Variable |
Label |
---|---|
moa1#1_1 |
imp_financialindependence |
moa1#1_2 |
imp_nolongerhom |
moa1#1_3 |
imp_finishededucation |
moa1#1_4 |
imp_married |
moa1#1_5 |
imp_havechild |
moa1#1_6 |
imp_settledcareer |
moa1#1_7 |
imp_avoiddrunk |
moa1#1_8 |
imp_avoiddrugs |
moa1#1_9 |
imp_usecontraception |
moa1#1_10 |
imp_committedlongterm |
moa1#2_1 |
ach_financialindependence |
moa1#2_2 |
ach_nolongerhome |
moa1#2_3 |
ach_finishededucation |
moa1#2_4 |
ach_married |
moa1#2_5 |
ach_havechild |
moa1#2_6 |
ach_settledcareer |
moa1#2_7 |
ach_avoiddrunk |
moa1#2_8 |
ach_avoiddrugs |
moa1#2_9 |
ach_usecontraception |
moa1#2_10 |
ach_committedlongterm |
moa2#1_1 |
imp_indepedentdecisions |
moa2#1_2 |
imp_supportfamily |
moa2#1_3 |
imp_carechildren |
moa2#1_4 |
imp_acceptresponsibility |
moa2#1_5 |
imp_employfulltime |
moa2#1_6 |
imp_avoiddrunkdriving |
moa2#1_7 |
imp_parentasequal |
moa2#1_8 |
imp_emotionalcontrol |
moa2#1_9 |
imp_considerothers |
moa2#1_10 |
imp_supportparentsfinance |
moa2#2_1 |
achi_independentdecisions |
moa2#2_2 |
ach_supportfamily |
moa2#2_3 |
ach_carechildren |
moa2#2_4 |
ach_acceptresponsibility |
moa2#2_5 |
ach_employfulltime |
moa2#2_6 |
ach_avoiddrunkdriving |
moa2#2_7 |
ach_parentasequal |
moa2#2_8 |
ach_emotionalcontrol |
moa2#2_9 |
ach_considerothers |
moa2#2_10 |
ach_supportparentsfinances |
IDEA_1 |
IDEA-manypossibility |
IDEA_2 |
IDEA-exploration |
IDEA_3 |
IDEA-stressed |
IDEA_4 |
IDEA-highpressure |
IDEA_5 |
IDEA-definingself |
IDEA_6 |
IDEA-beliefsvalues |
IDEA_7 |
IDEA-someways |
IDEA_8 |
IDEA-graduallyadult |
swb_1 |
SWB-ideal |
swb_2 |
SWB-excellent |
swb_3 |
SWB-satisfied |
swb_4 |
SWB-important |
swb_5 |
SWB-changenothing |
swb_6 |
SWB-highselfesteem |
mindful_1 |
MIND-emotnotconscious |
mindful_2 |
MIND-breakspill |
mindful_3 |
MIND-difficultfocus |
mindful_4 |
MIND-walknoattention |
mindful_5 |
MIND-notnoticetension |
mindful_6 |
MIND-forgetnames |
mindful_7 |
MIND-runautomatic |
mindful_8 |
MIND-rushactivities |
mindful_9 |
MIND-goalfocus |
mindful_10 |
MIND-jobautomatically |
mindful_11 |
MIND-listensametime |
mindful_12 |
MIND-driveautomatic |
mindful_13 |
MIND-preoccupied |
mindful_14 |
MIND-withoutpayattention |
mindful_15 |
MIND-snackunaware |
belong_1 |
Belong_nobother |
belong_2 |
Belong_avoidrejection |
belong_3 |
Belong_seldomworry |
belong_4 |
Belong_needpeople |
belong_5 |
Belong_othersacceptme |
belong_6 |
Belong_notalone |
belong_7 |
Belong_OKalone |
belong_8 |
Belong_strongNEED |
belong_9 |
Belong_bothernotinplans |
belong_10 |
Belong_feelingseasilyhurt |
belnow |
BELONG-feelIbelong |
efficacy_1 |
EFF-solvetryhard |
efficacy_2 |
EFF-getwhatwant |
efficacy_3 |
EFF-stick2goals |
efficacy_4 |
EFF-dealunexpected |
efficacy_5 |
EFF-resourceful |
efficacy_6 |
EFF-solvenecesseffort |
efficacy_7 |
EFF-remaincalm |
efficacy_8 |
EFF-findseveralsolutions |
efficacy_9 |
EFF-thinkofsolution |
efficacy_10 |
EFF-whatevercomesmyway |
support_1 |
SUP-specialforneed |
support_2 |
SUP-specialjoysorry. |
support_3 |
SUP-familyhelp |
support_4 |
SUP-familyemotionalhelp |
support_5 |
SUP-specialcomfort |
support_6 |
SUP-friendshelp |
support_7 |
SUP-countonfriends |
support_8 |
SUP-talkfamily |
support_9 |
SUP-friendsjoysorrow |
support_10 |
SUP-specialcaresfeelings |
support_11 |
SUP-familyhelpdecisions |
support_12 |
SUP-friendstalkproblems |
SocMedia_1 |
SocMed-avoiddrifting |
SocMedia_2 |
SocMed-friendsplanstonight |
SocMedia_3 |
SocMed-friendsintouch |
SocMedia_4 |
SocMed-friendsupto |
SocMedia_5 |
SocMed-Reconnectwithpeople |
SocMedia_6 |
SocMed-Findoutmore |
SocMedia_7 |
SocMed-someonetoknowbetter |
SocMedia_8 |
SocMed-makenewfriends |
SocMedia_9 |
SocMed-getintouch |
SocMedia_10 |
SocMed-getinformation |
SocMedia_11 |
SocMed-shareinformation |
usdream_1 |
AmDreamImport |
usdream_2 |
AmDreamAchieve |
usdream_3 |
attentionchechshould be1 |
transgres_1 |
trangress-lietoyou |
transgres_2 |
transgress-rumors |
transgres_3 |
transgress-goteven |
transgres_4 |
transgress-degraded |
NPI1 |
NPI1 |
NPI2 |
NPI2 |
NPI3 |
NPI3 |
NPI4 |
NPI4 |
NPI5 |
NPI5 |
NPI6 |
NPI6 |
NPI7 |
NPI7 |
NPI8 |
NPI8 |
NPI9 |
NPI9 |
NPI10 |
NPI10 |
NPI11 |
NPI11 |
NPI12 |
NPI12 |
NPI13 |
NPI13 |
exploit_1 |
EXP-benefitfromothers |
exploit_2 |
EXP-profitfromothers |
exploit_3 |
EXP-usingothers |
POQ1 |
DISID-disabilityinterferes |
POQ2 |
DISID-dontthinkdisabled |
POQ3 |
DISID-lackconfidence |
POQ4 |
DISID-proudtobedisabled |
POQ5 |
DISID-ashamed |
POQ6 |
DISID-notreducedenjoy |
POQ7 |
DISID-limitedfriendships |
POQ8 |
DISID-sourcestrength |
POQ9 |
DISID-accomplishmore |
POQ10 |
DISID-notaproblem |
POQ11 |
DISID-normallife |
POQ12 |
DISID-betterperson |
POQ13 |
DISID-importantpart |
POQ14 |
DISID-proudofdisability |
POQ15 |
DISID-disabilityenriches |
physSx_1 |
Phys_stomach |
physSx_2 |
Phys-back |
physSx_3 |
Phys-appendages |
physSx_4 |
Phys-headaches |
physSx_5 |
Phys-chest |
physSx_6 |
Phys-dizziness |
physSx_7 |
Phys-fainting |
physSx_8 |
Phys-heartpound |
physSx_9 |
Phys-shortness |
physSx_10 |
Phys-constipation |
physSx_11 |
Phys-nausea |
physSx_12 |
Phys-tired |
physSx_13 |
Phys-troublesleeping |
stress_1 |
stress-beenupset |
stress_2 |
stress-unablecontrol |
stress_3 |
stress-nervous |
stress_4 |
stress-confident |
stress_5 |
stress-goingmyway |
stress_6 |
stress-couldnotcope |
stress_7 |
stress-controlirritations |
stress_8 |
stress-ontopofthings |
stress_9 |
stress-beenangered |
stress_10 |
stress-feltdifficulties |
Variables in the working file |
EAMMi2 <- EAMMi2[complete.cases(EAMMi2),]
EAMMi2long <- EAMMi2 %>% pivot_longer(cols = everything()) %>%
dplyr::rename(item = name, score = value) %>%
group_by(item) %>%
sample_n(size = 50)
flextable(head(EAMMi2long)) %>% autofit()
item |
score |
---|---|
moa1#1_1 |
4 |
moa1#1_1 |
3 |
moa1#1_1 |
4 |
moa1#1_1 |
4 |
moa1#1_1 |
4 |
moa1#1_1 |
3 |
AIPE Analysis:
Stopping Rule
What the usual standard error for the data that could be considered for our stopping rule?
SE <- tapply(EAMMi2long$score, EAMMi2long$item, function (x) { sd(x)/sqrt(length(x)) })
min(SE)
#> [1] 0.04956958
quantile(SE, probs = .4)
#> 40%
#> 0.09805288
max(SE)
#> [1] 0.1781767
cutoff <- quantile(SE, probs = .4)
# we can also use semanticprimer's function
cutoff_score <- calculate_cutoff(population = EAMMi2long,
grouping_items = "item",
score = "score",
minimum = min(EAMMi2long$score),
maximum = max(EAMMi2long$score))
cutoff_score$cutoff
#> 40%
#> 0.09805288
The items have a range of 0.0495696 to 0.1781767. We could use the 40% decile SE = 0.0980529 as our critical value for our stopping rule given the manuscript results. We could also have a set SE to a specific item if we do not believe we have representative pilot data in this example. You should also consider the scale when estimating these values (i.e., 1-7 scales will have smaller estimates than 1-100 scales).
Minimum Sample Size
To estimate minimum sample size, we should figure out what number of participants it would take to achieve 80% of the SEs for items below our critical score of 0.0980529?
# sequence of sample sizes to try
nsim <- 10 # small for cran
samplesize_values <- seq(20, 200, 5)
# create a blank table for us to save the values in
sim_table <- matrix(NA,
nrow = length(samplesize_values)*nsim,
ncol = length(unique(EAMMi2long$item)))
# make it a data frame
sim_table <- as.data.frame(sim_table)
# add a place for sample size values
sim_table$sample_size <- NA
iterate <- 1
for (p in 1:nsim){
# loop over sample sizes
for (i in 1:length(samplesize_values)){
# temp dataframe that samples and summarizes
temp <- EAMMi2long %>%
group_by(item) %>%
sample_n(samplesize_values[i], replace = T) %>%
summarize(se = sd(score)/sqrt(length(score)))
colnames(sim_table)[1:length(unique(EAMMi2long$item))] <- temp$item
sim_table[iterate, 1:length(unique(EAMMi2long$item))] <- temp$se
sim_table[iterate, "sample_size"] <- samplesize_values[i]
sim_table[iterate, "nsim"] <- p
iterate <- iterate + 1
}
}
final_sample <-
sim_table %>%
pivot_longer(cols = -c(sample_size, nsim)) %>%
group_by(sample_size, nsim) %>%
summarize(percent_below = sum(value <= cutoff)/length(unique(EAMMi2long$item))) %>%
ungroup() %>%
# then summarize all down averaging percents
dplyr::group_by(sample_size) %>%
summarize(percent_below = mean(percent_below)) %>%
dplyr::arrange(percent_below) %>%
ungroup()
#> `summarise()` has grouped output by 'sample_size'. You can override using the
#> `.groups` argument.
flextable(final_sample %>% head()) %>% autofit()
sample_size |
percent_below |
---|---|
20 |
0.1125 |
25 |
0.1425 |
30 |
0.1950 |
35 |
0.2225 |
40 |
0.3050 |
45 |
0.3475 |
final_table <- calculate_correction(
proportion_summary = final_sample,
pilot_sample_size = EAMMi2long %>% group_by(item) %>%
summarize(sample_size = n()) %>% ungroup() %>%
summarize(avg_sample = mean(sample_size)) %>% pull(avg_sample),
proportion_variability = cutoff_score$prop_var
)
flextable(final_table) %>%
autofit()
percent_below |
sample_size |
corrected_sample_size |
---|---|---|
81.00 |
100 |
79.10863 |
85.50 |
110 |
86.31167 |
90.25 |
125 |
96.91896 |
97.25 |
155 |
116.99286 |
Based on these simulations, we can decide our minimum sample size is likely close to 79.
Maximum Sample Size
In this example, we could set our maximum sample size for 90% power, which would equate to 97 participants.
Final Sample Size
In any estimate for sample size, you should also consider the potential for missing data and/or unusable data due to any other exclusion criteria in your study (i.e., attention checks, speeding, getting the answer right, etc.). Another important note is that these estimates are driven by the number of items. Fewer items would require smaller sample sizes to achieve minimum power. Note: Several redundant (e.g., reverse coded items) and/or not useful variables (various checks) were omitted.