Note to self: these models take a long time to run, so, rather than estimating them each time I run the code, I’ve saved the models, commented out teh code for running the models, and included the code for opening the models. Be EXTRA CAREFUL that the saved models are the most up to date.
library(wordbankr) # WB data
library(tidyverse) # tidy
library(mirt) # IRT models
library(ltm) # more IRT functions
library(psych) # some psychometric stuff (tests of dimensionality)
library(Gifi)# some more psychometric stuff (tests of dimensionality)
library(knitr) # some formatting, tables, etc
library(patchwork) # combining plots.
library(GGally) # More plottinng options.
library(lordif) # differential item functioning.
Inst <- get_instrument_data(language="English (American)", form="WS")
Admin <- get_administration_data(language="English (American)", form="WS")
N_total = nrow(Admin) # making sure things add up later
N_long = nrow(filter(Admin, longitudinal==TRUE)) # making sure things add up later
Item <- get_item_data(language="English (American)", form = "WS")
Vocab <- Admin %>%
full_join(.,Inst, by="data_id") %>%
full_join(., Item, by="num_item_id") %>%
filter(longitudinal==FALSE) %>% # remove longitudinal data set
filter(type == "word"
) %>%
mutate(
out = ifelse(value=="produces", yes=1, no =0)
)
N_vocab = nrow(filter(Item, type == "word"))
nrow(Vocab) == (N_total - N_long)*N_vocab
## [1] TRUE
Vocab %>%
filter(is.na(out)) %>%
group_by(definition) %>%
count()
Number of missing items differs by word. How can this be??
Check distribution of missing values by source.
Vocab %>%
filter(is.na(out)) %>%
group_by(source_name) %>%
count()
These all seem to come from a single study (- 1).
Vocab %>%
group_by(source_name) %>%
count()
Vocab %>%
filter(is.na(out)) %>%
filter(source_name=="Marchman (Outreach1)")
No idea why this word is missing. I’m removing all these participants from the IRT models.
N_missing <- Vocab %>%
filter(is.na(out)) %>%
group_by(data_id) %>%
slice(1) %>%
ungroup(data_id) %>%
count()
Vocab %>%
filter(!is.na(out)) %>%
group_by(definition) %>%
summarise(
mean=mean(out),
sd=sd(out),
category = first(lexical_category)
) %>%
arrange(category) %>%
kable(caption="Means and SDs for Each Item (Arranged by Item)")
| definition | mean | sd | category |
|---|---|---|---|
| a | 0.2880992 | 0.4529315 | function_words |
| a lot | 0.1881848 | 0.3909063 | function_words |
| about | 0.0732872 | 0.2606384 | function_words |
| above | 0.0909308 | 0.2875450 | function_words |
| all | 0.3041925 | 0.4601194 | function_words |
| am | 0.1834009 | 0.3870410 | function_words |
| an | 0.0663643 | 0.2489475 | function_words |
| and | 0.2560191 | 0.4364845 | function_words |
| another | 0.2240229 | 0.4169869 | function_words |
| any | 0.1541766 | 0.3611611 | function_words |
| are | 0.1529103 | 0.3599440 | function_words |
| around | 0.1664679 | 0.3725446 | function_words |
| at | 0.2131617 | 0.4095898 | function_words |
| away | 0.2717961 | 0.4449383 | function_words |
| back | 0.3266667 | 0.4690500 | function_words |
| be | 0.1469466 | 0.3540949 | function_words |
| because | 0.1382191 | 0.3451711 | function_words |
| behind | 0.1869783 | 0.3899406 | function_words |
| beside | 0.0822996 | 0.2748534 | function_words |
| but | 0.0945333 | 0.2926042 | function_words |
| by | 0.1967096 | 0.3975583 | function_words |
| can (auxiliary) | 0.2479182 | 0.4318554 | function_words |
| could | 0.0761518 | 0.2652725 | function_words |
| did/did ya | 0.2269368 | 0.4189013 | function_words |
| do | 0.4020937 | 0.4903790 | function_words |
| does | 0.1195419 | 0.3244638 | function_words |
| don’t | 0.3340481 | 0.4717128 | function_words |
| down | 0.6519981 | 0.4763933 | function_words |
| each | 0.0591885 | 0.2360054 | function_words |
| every | 0.0983294 | 0.2977950 | function_words |
| for | 0.1870229 | 0.3899764 | function_words |
| gonna/going to | 0.2437574 | 0.4293991 | function_words |
| gotta/got to | 0.1350191 | 0.3417847 | function_words |
| hafta/have to | 0.1704057 | 0.3760337 | function_words |
| he | 0.2185115 | 0.4132855 | function_words |
| her | 0.1667860 | 0.3728292 | function_words |
| here | 0.3775607 | 0.4848346 | function_words |
| hers | 0.1147971 | 0.3188150 | function_words |
| him | 0.1550942 | 0.3620377 | function_words |
| his | 0.1400620 | 0.3470928 | function_words |
| how | 0.1537178 | 0.3607210 | function_words |
| I | 0.4377825 | 0.4961729 | function_words |
| if | 0.0603963 | 0.2382480 | function_words |
| inside/in | 0.4440210 | 0.4969157 | function_words |
| into | 0.1004534 | 0.3006394 | function_words |
| is | 0.2211883 | 0.4150965 | function_words |
| it | 0.3263409 | 0.4689296 | function_words |
| lemme/let me | 0.3024309 | 0.4593656 | function_words |
| me | 0.5405663 | 0.4984110 | function_words |
| mine | 0.6595340 | 0.4739223 | function_words |
| more | 0.6362340 | 0.4811396 | function_words |
| much | 0.1293556 | 0.3356332 | function_words |
| my | 0.3974756 | 0.4894342 | function_words |
| myself | 0.1390744 | 0.3460655 | function_words |
| need/need to | 0.2291369 | 0.4203276 | function_words |
| next to | 0.1212121 | 0.3264126 | function_words |
| none | 0.1499404 | 0.3570556 | function_words |
| not | 0.2356870 | 0.4244781 | function_words |
| of | 0.1002387 | 0.3003538 | function_words |
| off | 0.5752318 | 0.4943665 | function_words |
| on | 0.5615037 | 0.4962619 | function_words |
| on top of | 0.1905669 | 0.3927950 | function_words |
| other | 0.1967096 | 0.3975583 | function_words |
| our | 0.1071088 | 0.3092884 | function_words |
| out | 0.5418848 | 0.4983019 | function_words |
| over | 0.2550704 | 0.4359528 | function_words |
| same | 0.1370026 | 0.3438911 | function_words |
| she | 0.1881708 | 0.3908951 | function_words |
| so | 0.1137882 | 0.3175917 | function_words |
| some | 0.3160906 | 0.4650042 | function_words |
| that | 0.4465094 | 0.4971898 | function_words |
| the | 0.2462419 | 0.4308725 | function_words |
| their | 0.0835322 | 0.2767180 | function_words |
| them | 0.1216893 | 0.3269657 | function_words |
| then | 0.0887828 | 0.2844640 | function_words |
| there | 0.3482611 | 0.4764760 | function_words |
| these | 0.2051037 | 0.4038256 | function_words |
| they | 0.1150358 | 0.3191032 | function_words |
| this | 0.4040476 | 0.4907652 | function_words |
| those | 0.1500119 | 0.3571257 | function_words |
| to | 0.2435592 | 0.4292809 | function_words |
| too | 0.3306356 | 0.4704980 | function_words |
| try/try to | 0.2199190 | 0.4142409 | function_words |
| under | 0.2818680 | 0.4499630 | function_words |
| up | 0.6628653 | 0.4727875 | function_words |
| us | 0.0902363 | 0.2865543 | function_words |
| wanna/want to | 0.3738696 | 0.4838872 | function_words |
| was | 0.1100239 | 0.3129569 | function_words |
| we | 0.1528738 | 0.3599088 | function_words |
| were | 0.0701503 | 0.2554307 | function_words |
| what | 0.4424631 | 0.4967375 | function_words |
| when | 0.1067938 | 0.3088877 | function_words |
| where | 0.3529272 | 0.4779372 | function_words |
| which | 0.0765744 | 0.2659467 | function_words |
| who | 0.2293949 | 0.4204938 | function_words |
| why | 0.2638724 | 0.4407834 | function_words |
| will | 0.1321880 | 0.3387355 | function_words |
| with | 0.2200763 | 0.4143473 | function_words |
| would | 0.0601576 | 0.2378069 | function_words |
| you | 0.4323103 | 0.4954559 | function_words |
| your | 0.1764425 | 0.3812417 | function_words |
| yourself | 0.0611124 | 0.2395650 | function_words |
| airplane | 0.6494772 | 0.4771904 | nouns |
| alligator | 0.3564286 | 0.4790009 | nouns |
| animal | 0.4225553 | 0.4940247 | nouns |
| ankle | 0.1731044 | 0.3783826 | nouns |
| ant | 0.3986663 | 0.4896821 | nouns |
| apple | 0.7561728 | 0.4294406 | nouns |
| applesauce | 0.3798523 | 0.4854077 | nouns |
| arm | 0.5634506 | 0.4960166 | nouns |
| backyard | 0.2776454 | 0.4478909 | nouns |
| ball | 0.9344729 | 0.2474829 | nouns |
| balloon | 0.7591449 | 0.4276533 | nouns |
| banana | 0.8015195 | 0.3989032 | nouns |
| basement | 0.1137068 | 0.3174927 | nouns |
| basket | 0.3689228 | 0.4825705 | nouns |
| bat | 0.3419170 | 0.4744085 | nouns |
| bathroom | 0.4662387 | 0.4989182 | nouns |
| bathtub | 0.5354256 | 0.4988027 | nouns |
| beads | 0.2361641 | 0.4247748 | nouns |
| beans | 0.4151393 | 0.4928047 | nouns |
| bear | 0.6807701 | 0.4662337 | nouns |
| bed | 0.6421953 | 0.4794112 | nouns |
| bedroom | 0.3618844 | 0.4806028 | nouns |
| bee | 0.5981931 | 0.4903216 | nouns |
| belly button | 0.6276748 | 0.4834819 | nouns |
| belt | 0.3370653 | 0.4727637 | nouns |
| bench | 0.1424141 | 0.3495161 | nouns |
| bib | 0.4611905 | 0.4985509 | nouns |
| bicycle | 0.5744529 | 0.4944845 | nouns |
| bird | 0.7736342 | 0.4185283 | nouns |
| blanket | 0.6408551 | 0.4798068 | nouns |
| block | 0.5700690 | 0.4951249 | nouns |
| boat | 0.6286258 | 0.4832297 | nouns |
| book | 0.8252612 | 0.3797887 | nouns |
| boots | 0.5310050 | 0.4990971 | nouns |
| bottle | 0.6626277 | 0.4728693 | nouns |
| bowl | 0.5142653 | 0.4998559 | nouns |
| box | 0.5393392 | 0.4985093 | nouns |
| bread | 0.5680684 | 0.4954039 | nouns |
| broom | 0.4469553 | 0.4972374 | nouns |
| brush | 0.5483718 | 0.4977138 | nouns |
| bubbles | 0.7375297 | 0.4400291 | nouns |
| bucket | 0.3326185 | 0.4712073 | nouns |
| bug | 0.5823417 | 0.4932319 | nouns |
| bunny | 0.6228300 | 0.4847357 | nouns |
| bus | 0.6181430 | 0.4858995 | nouns |
| butter | 0.4138095 | 0.4925738 | nouns |
| butterfly | 0.4919163 | 0.4999941 | nouns |
| buttocks/bottom* | 0.5435093 | 0.4981626 | nouns |
| button | 0.5203329 | 0.4996458 | nouns |
| cake | 0.5509865 | 0.4974527 | nouns |
| camera | 0.3567349 | 0.4790926 | nouns |
| can (object) | 0.2736164 | 0.4458676 | nouns |
| candy | 0.5248632 | 0.4994409 | nouns |
| car | 0.8015195 | 0.3989032 | nouns |
| carrots | 0.4493581 | 0.4974879 | nouns |
| cat | 0.7432914 | 0.4368691 | nouns |
| cereal | 0.5509039 | 0.4974612 | nouns |
| chair | 0.6222381 | 0.4848853 | nouns |
| chalk | 0.2784538 | 0.4482915 | nouns |
| cheek | 0.4803805 | 0.4996743 | nouns |
| cheerios | 0.4682219 | 0.4990485 | nouns |
| cheese | 0.7418665 | 0.4376598 | nouns |
| chicken (animal) | 0.5065367 | 0.5000167 | nouns |
| chicken (food) | 0.5152091 | 0.4998280 | nouns |
| chin | 0.4496788 | 0.4975205 | nouns |
| chocolate | 0.3837016 | 0.4863444 | nouns |
| clock | 0.5005951 | 0.5000592 | nouns |
| closet | 0.3162027 | 0.4650484 | nouns |
| cloud | 0.3620567 | 0.4806523 | nouns |
| coat | 0.5299857 | 0.4991594 | nouns |
| coffee | 0.3933413 | 0.4885496 | nouns |
| coke | 0.2531011 | 0.4348403 | nouns |
| comb | 0.3961905 | 0.4891631 | nouns |
| cookie | 0.7491686 | 0.4335431 | nouns |
| corn | 0.4412955 | 0.4966010 | nouns |
| couch | 0.4124079 | 0.4923264 | nouns |
| cow | 0.6623901 | 0.4729509 | nouns |
| cracker | 0.6775268 | 0.4674786 | nouns |
| crayon | 0.4967880 | 0.5000492 | nouns |
| crib | 0.3540181 | 0.4782715 | nouns |
| cup | 0.6927096 | 0.4614256 | nouns |
| deer | 0.3295969 | 0.4701229 | nouns |
| diaper | 0.6907535 | 0.4622379 | nouns |
| dish | 0.2905840 | 0.4540860 | nouns |
| dog | 0.8717949 | 0.3343578 | nouns |
| doll | 0.5446535 | 0.4980614 | nouns |
| donkey | 0.2458899 | 0.4306649 | nouns |
| donut | 0.3157644 | 0.4648750 | nouns |
| door | 0.6521739 | 0.4763371 | nouns |
| drawer | 0.2594620 | 0.4383916 | nouns |
| dress (object) | 0.3691355 | 0.4826282 | nouns |
| drink (beverage) | 0.5915258 | 0.4916102 | nouns |
| dryer | 0.2338652 | 0.4233379 | nouns |
| duck | 0.7712589 | 0.4200720 | nouns |
| ear | 0.7695415 | 0.4211764 | nouns |
| egg | 0.5504631 | 0.4975060 | nouns |
| elephant | 0.5130703 | 0.4998885 | nouns |
| eye | 0.7957730 | 0.4031835 | nouns |
| face | 0.4549132 | 0.4980223 | nouns |
| finger | 0.5783591 | 0.4938804 | nouns |
| firetruck | 0.4208522 | 0.4937547 | nouns |
| fish (animal) | 0.7146591 | 0.4516303 | nouns |
| fish (food) | 0.5414785 | 0.4983358 | nouns |
| flag | 0.3171197 | 0.4654100 | nouns |
| flower | 0.6351962 | 0.4814324 | nouns |
| food | 0.4759638 | 0.4994814 | nouns |
| foot | 0.6146898 | 0.4867264 | nouns |
| fork | 0.5604944 | 0.4963859 | nouns |
| french fries | 0.4996431 | 0.5000594 | nouns |
| frog | 0.5521429 | 0.4973329 | nouns |
| game | 0.3192857 | 0.4662554 | nouns |
| garage | 0.2960667 | 0.4565752 | nouns |
| garbage | 0.3408605 | 0.4740549 | nouns |
| garden | 0.2079161 | 0.4058648 | nouns |
| giraffe | 0.4244587 | 0.4943194 | nouns |
| glass | 0.3580776 | 0.4794922 | nouns |
| glasses | 0.4750238 | 0.4994352 | nouns |
| gloves | 0.2803805 | 0.4492385 | nouns |
| glue | 0.1801287 | 0.3843404 | nouns |
| goose | 0.2875536 | 0.4526758 | nouns |
| grapes | 0.5568236 | 0.4968197 | nouns |
| grass | 0.4738344 | 0.4993743 | nouns |
| green beans | 0.2828211 | 0.4504239 | nouns |
| gum | 0.3044100 | 0.4602120 | nouns |
| hair | 0.6860603 | 0.4641473 | nouns |
| hamburger | 0.3956149 | 0.4890406 | nouns |
| hammer | 0.3424690 | 0.4745921 | nouns |
| hand | 0.6040380 | 0.4891144 | nouns |
| hat | 0.7295821 | 0.4442284 | nouns |
| head | 0.5828381 | 0.4931487 | nouns |
| helicopter | 0.3828218 | 0.4861332 | nouns |
| hen | 0.1760496 | 0.3809078 | nouns |
| high chair | 0.3623810 | 0.4807453 | nouns |
| horse | 0.6391067 | 0.4803167 | nouns |
| hose | 0.2711016 | 0.4445814 | nouns |
| ice | 0.5113015 | 0.4999317 | nouns |
| ice cream | 0.5624257 | 0.4961467 | nouns |
| jacket | 0.4549774 | 0.4980280 | nouns |
| jar | 0.3068480 | 0.4612408 | nouns |
| jeans | 0.2605382 | 0.4389806 | nouns |
| jello | 0.2449905 | 0.4301328 | nouns |
| jelly | 0.3033413 | 0.4597562 | nouns |
| juice | 0.7488129 | 0.4337474 | nouns |
| keys | 0.5450440 | 0.4980261 | nouns |
| kitchen | 0.4399524 | 0.4964402 | nouns |
| kitty | 0.7184004 | 0.4498327 | nouns |
| knee | 0.5183246 | 0.4997236 | nouns |
| knife | 0.3726190 | 0.4835595 | nouns |
| ladder | 0.2650775 | 0.4414271 | nouns |
| lamb | 0.2948321 | 0.4560216 | nouns |
| lamp | 0.2573267 | 0.4372130 | nouns |
| lawn mower | 0.3077290 | 0.4616088 | nouns |
| leg | 0.5023798 | 0.5000538 | nouns |
| light | 0.6280285 | 0.4833883 | nouns |
| lion | 0.4963139 | 0.5000459 | nouns |
| lips | 0.3697359 | 0.4827906 | nouns |
| living room | 0.2560076 | 0.4364780 | nouns |
| lollipop | 0.2740935 | 0.4461096 | nouns |
| meat | 0.3506308 | 0.4772243 | nouns |
| medicine | 0.4221429 | 0.4939599 | nouns |
| melon | 0.2656027 | 0.4417062 | nouns |
| milk | 0.7565899 | 0.4291915 | nouns |
| mittens | 0.2788484 | 0.4484862 | nouns |
| money | 0.4702664 | 0.4991745 | nouns |
| monkey | 0.5874109 | 0.4923585 | nouns |
| moon | 0.6044244 | 0.4890321 | nouns |
| moose | 0.2189659 | 0.4135947 | nouns |
| mop | 0.1989516 | 0.3992591 | nouns |
| motorcycle | 0.3676436 | 0.4822211 | nouns |
| mouse | 0.4954762 | 0.5000391 | nouns |
| mouth | 0.6562871 | 0.4750031 | nouns |
| muffin | 0.3313497 | 0.4707545 | nouns |
| nail | 0.2336271 | 0.4231880 | nouns |
| napkin | 0.3977137 | 0.4894840 | nouns |
| necklace | 0.3558677 | 0.4788324 | nouns |
| noodles | 0.4462672 | 0.4971635 | nouns |
| nose | 0.8000950 | 0.3999762 | nouns |
| nuts | 0.2777513 | 0.4479434 | nouns |
| orange (food) | 0.5114068 | 0.4999293 | nouns |
| oven | 0.2948596 | 0.4560339 | nouns |
| owie/boo boo | 0.6778332 | 0.4673620 | nouns |
| owl | 0.4559733 | 0.4981172 | nouns |
| pajamas | 0.4845385 | 0.4998203 | nouns |
| pancake | 0.4289116 | 0.4949796 | nouns |
| pants | 0.5471833 | 0.4978279 | nouns |
| paper | 0.5161674 | 0.4997980 | nouns |
| peanut butter | 0.4073810 | 0.4914053 | nouns |
| peas | 0.4185714 | 0.4933836 | nouns |
| pen | 0.4506070 | 0.4976136 | nouns |
| pencil | 0.3704145 | 0.4829732 | nouns |
| penguin | 0.3013568 | 0.4589020 | nouns |
| penis* | 0.3288128 | 0.4698377 | nouns |
| penny | 0.2992370 | 0.4579784 | nouns |
| pickle | 0.3379442 | 0.4730658 | nouns |
| picture | 0.4351654 | 0.4958376 | nouns |
| pig | 0.6202471 | 0.4853830 | nouns |
| pillow | 0.5320817 | 0.4990290 | nouns |
| pizza | 0.5870753 | 0.4924180 | nouns |
| plant | 0.3149119 | 0.4645361 | nouns |
| plate | 0.4399239 | 0.4964368 | nouns |
| play dough | 0.2932349 | 0.4552994 | nouns |
| play pen | 0.1038434 | 0.3050937 | nouns |
| pony | 0.2598951 | 0.4386291 | nouns |
| pool | 0.4626190 | 0.4986601 | nouns |
| popcorn | 0.4464030 | 0.4971783 | nouns |
| popsicle | 0.3614688 | 0.4804832 | nouns |
| porch | 0.1699284 | 0.3756147 | nouns |
| potato | 0.3719933 | 0.4833942 | nouns |
| potato chip | 0.4204004 | 0.4936821 | nouns |
| potty | 0.6090369 | 0.4880242 | nouns |
| present | 0.3602381 | 0.4801265 | nouns |
| pretzel | 0.3295184 | 0.4700944 | nouns |
| pudding | 0.2128370 | 0.4093622 | nouns |
| pumpkin | 0.3634849 | 0.4810600 | nouns |
| puppy | 0.6105163 | 0.4876912 | nouns |
| purse | 0.3965722 | 0.4892440 | nouns |
| puzzle | 0.4194623 | 0.4935298 | nouns |
| radio | 0.2714932 | 0.4447828 | nouns |
| rain | 0.5482414 | 0.4977265 | nouns |
| raisin | 0.4431223 | 0.4968135 | nouns |
| refrigerator | 0.3361085 | 0.4724327 | nouns |
| rock | 0.5506073 | 0.4974916 | nouns |
| rocking chair | 0.3219652 | 0.4672854 | nouns |
| roof | 0.1909871 | 0.3931258 | nouns |
| room | 0.3956698 | 0.4890523 | nouns |
| rooster | 0.2502383 | 0.4332018 | nouns |
| salt | 0.2187277 | 0.4134327 | nouns |
| sandbox | 0.2675888 | 0.4427548 | nouns |
| sandwich | 0.3955259 | 0.4890216 | nouns |
| sauce | 0.2488688 | 0.4324091 | nouns |
| scarf | 0.1403383 | 0.3473791 | nouns |
| scissors | 0.3413473 | 0.4742181 | nouns |
| sheep | 0.4704065 | 0.4991828 | nouns |
| shirt | 0.5708512 | 0.4950135 | nouns |
| shoe | 0.8566002 | 0.3505217 | nouns |
| shorts | 0.3854216 | 0.4867527 | nouns |
| shoulder | 0.2709078 | 0.4444815 | nouns |
| shovel | 0.3355545 | 0.4722401 | nouns |
| shower | 0.4426736 | 0.4967619 | nouns |
| sidewalk | 0.2502980 | 0.4332362 | nouns |
| sink | 0.3630952 | 0.4809492 | nouns |
| sky | 0.4303376 | 0.4951822 | nouns |
| sled | 0.2291369 | 0.4203276 | nouns |
| slide (object) | 0.4940561 | 0.5000241 | nouns |
| slipper | 0.3030736 | 0.4596415 | nouns |
| sneaker | 0.1923169 | 0.3941677 | nouns |
| snow | 0.4007606 | 0.4901109 | nouns |
| snowman | 0.2750832 | 0.4466093 | nouns |
| snowsuit | 0.0924690 | 0.2897214 | nouns |
| soap | 0.5214082 | 0.4996009 | nouns |
| sock | 0.5849370 | 0.4927914 | nouns |
| soda/pop | 0.3278454 | 0.4694842 | nouns |
| sofa | 0.1728248 | 0.3781408 | nouns |
| soup | 0.3962444 | 0.4891745 | nouns |
| spaghetti | 0.4167659 | 0.4930821 | nouns |
| spoon | 0.6611256 | 0.4733833 | nouns |
| sprinkler | 0.2004773 | 0.4004053 | nouns |
| squirrel | 0.3954318 | 0.4890014 | nouns |
| stairs | 0.3771116 | 0.4847209 | nouns |
| star | 0.5228245 | 0.4995382 | nouns |
| stick | 0.4180562 | 0.4932983 | nouns |
| stone | 0.1685742 | 0.3744200 | nouns |
| story | 0.3909631 | 0.4880242 | nouns |
| stove | 0.3399952 | 0.4737635 | nouns |
| strawberry | 0.4414843 | 0.4966232 | nouns |
| street | 0.3465841 | 0.4759385 | nouns |
| stroller | 0.3573638 | 0.4792803 | nouns |
| sun | 0.5001190 | 0.5000595 | nouns |
| sweater | 0.4615751 | 0.4985807 | nouns |
| swing (object) | 0.5610278 | 0.4963207 | nouns |
| table | 0.4639715 | 0.4987596 | nouns |
| tape | 0.3211818 | 0.4669861 | nouns |
| teddybear | 0.4754879 | 0.4994582 | nouns |
| telephone | 0.5985263 | 0.4902547 | nouns |
| tiger | 0.4462161 | 0.4971580 | nouns |
| tights | 0.1463996 | 0.3535485 | nouns |
| tissue/kleenex | 0.3886245 | 0.4874957 | nouns |
| toast | 0.4727576 | 0.4993167 | nouns |
| toe | 0.6043251 | 0.4890533 | nouns |
| tongue | 0.4879848 | 0.4999151 | nouns |
| tooth | 0.5522814 | 0.4973182 | nouns |
| toothbrush | 0.5775719 | 0.4940046 | nouns |
| towel | 0.4853885 | 0.4998458 | nouns |
| toy (object) | 0.5885714 | 0.4921512 | nouns |
| tractor | 0.3786870 | 0.4851176 | nouns |
| train | 0.6135932 | 0.4869835 | nouns |
| trash | 0.4232514 | 0.4941335 | nouns |
| tray | 0.1245526 | 0.3302503 | nouns |
| tree | 0.6509030 | 0.4767413 | nouns |
| tricycle | 0.2079657 | 0.4059005 | nouns |
| truck | 0.7133349 | 0.4522575 | nouns |
| tummy | 0.5853137 | 0.4927264 | nouns |
| tuna | 0.1726687 | 0.3780057 | nouns |
| turkey | 0.3153003 | 0.4646907 | nouns |
| turtle | 0.5105877 | 0.4999474 | nouns |
| TV | 0.5713946 | 0.4949354 | nouns |
| underpants | 0.2497617 | 0.4329266 | nouns |
| vacuum | 0.4149012 | 0.4927636 | nouns |
| vagina* | 0.1793893 | 0.3837237 | nouns |
| vanilla | 0.1302481 | 0.3366163 | nouns |
| vitamins | 0.2785595 | 0.4483437 | nouns |
| walker | 0.0866348 | 0.2813328 | nouns |
| washing machine | 0.2921830 | 0.4548202 | nouns |
| watch (object) | 0.4146225 | 0.4927154 | nouns |
| water (beverage) | 0.7003087 | 0.4581771 | nouns |
| water (not beverage) | 0.6805984 | 0.4663002 | nouns |
| wind | 0.3337298 | 0.4716006 | nouns |
| window | 0.3780314 | 0.4849532 | nouns |
| wolf | 0.2246066 | 0.4173727 | nouns |
| yogurt | 0.4806275 | 0.4996840 | nouns |
| zebra | 0.3829686 | 0.4861686 | nouns |
| zipper | 0.4020937 | 0.4903790 | nouns |
| after | 0.1699595 | 0.3756420 | other |
| aunt | 0.3533191 | 0.4780576 | other |
| baa baa | 0.7287411 | 0.4446622 | other |
| baby | 0.8380817 | 0.3684196 | other |
| babysitter | 0.1183488 | 0.3230593 | other |
| babysitter’s name | 0.4131936 | 0.4924656 | other |
| bath | 0.7432304 | 0.4369031 | other |
| beach | 0.2987601 | 0.4577690 | other |
| before | 0.0990453 | 0.2987585 | other |
| boy | 0.4841704 | 0.4998089 | other |
| breakfast | 0.4298976 | 0.4951202 | other |
| brother | 0.3183333 | 0.4658851 | other |
| bye | 0.9054856 | 0.2925777 | other |
| call (on phone) | 0.4613739 | 0.4985650 | other |
| camping | 0.1088305 | 0.3114637 | other |
| child | 0.1243746 | 0.3300477 | other |
| child’s own name | 0.6618380 | 0.4731402 | other |
| choo choo | 0.6794202 | 0.4667549 | other |
| church* | 0.3188648 | 0.4660921 | other |
| circus | 0.1276850 | 0.3337785 | other |
| clown | 0.2729008 | 0.4455034 | other |
| cockadoodledoo | 0.3926190 | 0.4883914 | other |
| country | 0.0515144 | 0.2210709 | other |
| cowboy | 0.1372315 | 0.3441327 | other |
| daddy* | 0.9648623 | 0.1841497 | other |
| day | 0.2262443 | 0.4184490 | other |
| dinner | 0.4125208 | 0.4923465 | other |
| doctor | 0.4054247 | 0.4910325 | other |
| downtown | 0.0930565 | 0.2905463 | other |
| farm | 0.2417896 | 0.4282184 | other |
| fireman | 0.2301644 | 0.4209881 | other |
| friend | 0.2901690 | 0.4538943 | other |
| gas station | 0.1976633 | 0.3982843 | other |
| girl | 0.4431223 | 0.4968135 | other |
| give me five! | 0.3927212 | 0.4884138 | other |
| go potty | 0.5183159 | 0.4997239 | other |
| gonna get you! | 0.4020029 | 0.4903610 | other |
| grandma* | 0.7577773 | 0.4284793 | other |
| grandpa* | 0.7015918 | 0.4576139 | other |
| grrr | 0.7302569 | 0.4438791 | other |
| hello | 0.6792587 | 0.4668170 | other |
| hi | 0.8012821 | 0.3990826 | other |
| home | 0.5773343 | 0.4940419 | other |
| house | 0.5154468 | 0.4998207 | other |
| lady | 0.2540515 | 0.4353786 | other |
| later | 0.2443385 | 0.4297455 | other |
| lunch | 0.4192244 | 0.4934909 | other |
| mailman | 0.2196518 | 0.4140601 | other |
| man | 0.3696118 | 0.4827571 | other |
| meow | 0.7923990 | 0.4056376 | other |
| mommy* | 0.9705603 | 0.1690556 | other |
| moo | 0.8180523 | 0.3858473 | other |
| morning | 0.2954059 | 0.4562793 | other |
| movie | 0.2785442 | 0.4483360 | other |
| nap | 0.5176023 | 0.4997495 | other |
| night | 0.4167460 | 0.4930787 | other |
| night night | 0.7487521 | 0.4337824 | other |
| no | 0.8765139 | 0.3290334 | other |
| now | 0.3493689 | 0.4768275 | other |
| nurse | 0.1098114 | 0.3126919 | other |
| ouch | 0.7516029 | 0.4321346 | other |
| outside | 0.6558117 | 0.4751593 | other |
| park | 0.4903732 | 0.4999667 | other |
| party | 0.3216667 | 0.4671715 | other |
| pattycake | 0.3786038 | 0.4850969 | other |
| peekaboo | 0.6747388 | 0.4685280 | other |
| people | 0.2880952 | 0.4529296 | other |
| person | 0.1027659 | 0.3036890 | other |
| pet’s name | 0.5483103 | 0.4977199 | other |
| picnic | 0.2074392 | 0.4055211 | other |
| playground | 0.2530408 | 0.4348060 | other |
| please | 0.7264957 | 0.4458104 | other |
| police | 0.1993807 | 0.3995823 | other |
| quack quack | 0.7276616 | 0.4452160 | other |
| school | 0.4652712 | 0.4988518 | other |
| shh/shush/hush | 0.6975529 | 0.4593724 | other |
| shopping | 0.3358742 | 0.4723514 | other |
| sister | 0.3280171 | 0.4695470 | other |
| snack | 0.4508450 | 0.4976372 | other |
| so big! | 0.3299214 | 0.4702403 | other |
| store | 0.4527943 | 0.4978258 | other |
| teacher | 0.2279657 | 0.4195703 | other |
| thank you | 0.7466762 | 0.4349664 | other |
| this little piggy | 0.3048548 | 0.4604007 | other |
| time | 0.1298020 | 0.3361255 | other |
| today | 0.1891827 | 0.3917004 | other |
| tomorrow | 0.1934176 | 0.3950246 | other |
| tonight | 0.1309325 | 0.3373668 | other |
| turn around | 0.3199334 | 0.4665059 | other |
| uh oh | 0.8981481 | 0.3024893 | other |
| uncle | 0.3387250 | 0.4733325 | other |
| vroom | 0.6611905 | 0.4733614 | other |
| woods | 0.1059160 | 0.3077668 | other |
| woof woof | 0.8007126 | 0.3995120 | other |
| work (place) | 0.4351345 | 0.4958336 | other |
| yard | 0.2588263 | 0.4380423 | other |
| yes | 0.7515439 | 0.4321690 | other |
| yesterday | 0.0894775 | 0.2854657 | other |
| yum yum | 0.6779258 | 0.4673268 | other |
| zoo | 0.3522267 | 0.4777211 | other |
| all gone | 0.6881388 | 0.4633085 | predicates |
| asleep | 0.4006189 | 0.4900822 | predicates |
| awake | 0.3227803 | 0.4675951 | predicates |
| bad | 0.3896289 | 0.4877241 | predicates |
| better | 0.2772749 | 0.4477067 | predicates |
| big | 0.5260404 | 0.4993808 | predicates |
| bite | 0.5424495 | 0.4982540 | predicates |
| black | 0.3264335 | 0.4689637 | predicates |
| blow | 0.4316290 | 0.4953623 | predicates |
| blue | 0.4983365 | 0.5000567 | predicates |
| break | 0.3884789 | 0.4874624 | predicates |
| bring | 0.2901308 | 0.4538765 | predicates |
| broken | 0.4642093 | 0.4987767 | predicates |
| brown | 0.2874822 | 0.4526422 | predicates |
| build | 0.2670793 | 0.4424868 | predicates |
| bump | 0.3404762 | 0.4739258 | predicates |
| buy | 0.2512503 | 0.4337838 | predicates |
| careful | 0.3187991 | 0.4660665 | predicates |
| carry | 0.3573130 | 0.4792652 | predicates |
| catch | 0.3560894 | 0.4788991 | predicates |
| chase | 0.2345091 | 0.4237421 | predicates |
| clap | 0.4636061 | 0.4987330 | predicates |
| clean (action) | 0.4282319 | 0.4948813 | predicates |
| clean (description) | 0.4492754 | 0.4974795 | predicates |
| climb | 0.3463554 | 0.4758648 | predicates |
| close | 0.4105063 | 0.4919842 | predicates |
| cold | 0.6041815 | 0.4890839 | predicates |
| cook | 0.3773810 | 0.4847892 | predicates |
| cover | 0.2289731 | 0.4202219 | predicates |
| cry | 0.4798004 | 0.4996512 | predicates |
| cut | 0.2956708 | 0.4563980 | predicates |
| cute | 0.2876549 | 0.4527233 | predicates |
| dance | 0.4749108 | 0.4994295 | predicates |
| dark | 0.3337301 | 0.4716007 | predicates |
| dirty | 0.5362491 | 0.4987435 | predicates |
| draw | 0.3559362 | 0.4788530 | predicates |
| drink (action) | 0.5935791 | 0.4912233 | predicates |
| drive | 0.3802616 | 0.4855088 | predicates |
| drop | 0.3289693 | 0.4698947 | predicates |
| dry (action) | 0.2999762 | 0.4583018 | predicates |
| dry (description) | 0.3220501 | 0.4673177 | predicates |
| dump | 0.1879323 | 0.3907047 | predicates |
| eat | 0.6677757 | 0.4710669 | predicates |
| empty | 0.3127533 | 0.4636700 | predicates |
| fall | 0.4714829 | 0.4992454 | predicates |
| fast | 0.3359505 | 0.4723779 | predicates |
| feed | 0.2880629 | 0.4529145 | predicates |
| find | 0.3425309 | 0.4746125 | predicates |
| fine | 0.1484747 | 0.3556123 | predicates |
| finish | 0.2315189 | 0.4218533 | predicates |
| first | 0.2107773 | 0.4079092 | predicates |
| fit | 0.1986171 | 0.3990066 | predicates |
| fix | 0.3751189 | 0.4842112 | predicates |
| full | 0.2733556 | 0.4457350 | predicates |
| gentle | 0.2666032 | 0.4422358 | predicates |
| get | 0.4378867 | 0.4961860 | predicates |
| give | 0.3334127 | 0.4714887 | predicates |
| go | 0.6885246 | 0.4631516 | predicates |
| good | 0.4463734 | 0.4971750 | predicates |
| green | 0.4156956 | 0.4929001 | predicates |
| happy | 0.4344106 | 0.4957383 | predicates |
| hard | 0.2401716 | 0.4272384 | predicates |
| hate | 0.0756202 | 0.2644210 | predicates |
| have | 0.3242857 | 0.4681631 | predicates |
| hear | 0.2852724 | 0.4515978 | predicates |
| heavy | 0.3832421 | 0.4862344 | predicates |
| help | 0.5134300 | 0.4998790 | predicates |
| hide | 0.3578396 | 0.4794216 | predicates |
| high | 0.3018823 | 0.4591292 | predicates |
| hit | 0.4074250 | 0.4914136 | predicates |
| hold | 0.3707758 | 0.4830700 | predicates |
| hot | 0.7430473 | 0.4370050 | predicates |
| hug | 0.5676576 | 0.4954602 | predicates |
| hungry | 0.4234706 | 0.4941674 | predicates |
| hurry | 0.2589328 | 0.4381008 | predicates |
| hurt | 0.4079010 | 0.4915031 | predicates |
| jump | 0.4939387 | 0.5000227 | predicates |
| kick | 0.4166072 | 0.4930552 | predicates |
| kiss | 0.6005706 | 0.4898394 | predicates |
| knock | 0.3545390 | 0.4784304 | predicates |
| last | 0.1111906 | 0.3144056 | predicates |
| lick | 0.2514884 | 0.4339203 | predicates |
| like | 0.3291290 | 0.4699528 | predicates |
| listen | 0.2366667 | 0.4250866 | predicates |
| little (description) | 0.3582658 | 0.4795479 | predicates |
| long | 0.1536260 | 0.3606328 | predicates |
| look | 0.4405611 | 0.4965135 | predicates |
| loud | 0.3029293 | 0.4595796 | predicates |
| love | 0.4964354 | 0.5000467 | predicates |
| mad | 0.2211905 | 0.4150979 | predicates |
| make | 0.2789148 | 0.4485189 | predicates |
| naughty | 0.1334129 | 0.3400610 | predicates |
| new | 0.2278571 | 0.4194999 | predicates |
| nice | 0.3726190 | 0.4835595 | predicates |
| noisy | 0.2248450 | 0.4175300 | predicates |
| old | 0.1711969 | 0.3767259 | predicates |
| open | 0.5611784 | 0.4963020 | predicates |
| orange (description) | 0.4218156 | 0.4939081 | predicates |
| paint | 0.3121277 | 0.4634168 | predicates |
| pick | 0.2222222 | 0.4157893 | predicates |
| play | 0.5127229 | 0.4998975 | predicates |
| poor | 0.0809262 | 0.2727544 | predicates |
| pour | 0.2326579 | 0.4225764 | predicates |
| pretend | 0.1358760 | 0.3426977 | predicates |
| pretty | 0.4186324 | 0.4933937 | predicates |
| pull | 0.3208671 | 0.4668654 | predicates |
| push | 0.4059005 | 0.4911239 | predicates |
| put | 0.2888095 | 0.4532632 | predicates |
| quiet | 0.2880952 | 0.4529296 | predicates |
| read | 0.5184392 | 0.4997193 | predicates |
| red | 0.4394011 | 0.4963732 | predicates |
| ride | 0.4271429 | 0.4947223 | predicates |
| rip | 0.1364178 | 0.3432727 | predicates |
| run | 0.4604950 | 0.4984962 | predicates |
| sad | 0.3032105 | 0.4597000 | predicates |
| say | 0.2728139 | 0.4454590 | predicates |
| scared | 0.2863604 | 0.4521137 | predicates |
| see | 0.5043995 | 0.5000401 | predicates |
| shake | 0.2776588 | 0.4478975 | predicates |
| share | 0.3030014 | 0.4596106 | predicates |
| show | 0.2612011 | 0.4393417 | predicates |
| sick | 0.2899000 | 0.4537698 | predicates |
| sing | 0.4096099 | 0.4918203 | predicates |
| sit | 0.5562158 | 0.4968888 | predicates |
| skate | 0.1334923 | 0.3401465 | predicates |
| sleep | 0.5014265 | 0.5000574 | predicates |
| sleepy | 0.3601049 | 0.4800878 | predicates |
| slide (action) | 0.4233698 | 0.4941517 | predicates |
| slow | 0.1975220 | 0.3981769 | predicates |
| smile | 0.2900691 | 0.4538481 | predicates |
| soft | 0.3267445 | 0.4690788 | predicates |
| spill | 0.2945385 | 0.4558894 | predicates |
| splash | 0.3590660 | 0.4797838 | predicates |
| stand | 0.3130062 | 0.4637721 | predicates |
| stay | 0.3027130 | 0.4594868 | predicates |
| sticky | 0.3206470 | 0.4667808 | predicates |
| stop | 0.5101022 | 0.4999574 | predicates |
| stuck | 0.3497020 | 0.4769326 | predicates |
| sweep | 0.3095068 | 0.4623454 | predicates |
| swim | 0.4080952 | 0.4915395 | predicates |
| swing (action) | 0.4974994 | 0.5000533 | predicates |
| take | 0.2797903 | 0.4489496 | predicates |
| talk | 0.3221429 | 0.4673530 | predicates |
| taste | 0.2305311 | 0.4212229 | predicates |
| tear | 0.1624523 | 0.3689092 | predicates |
| think | 0.1340010 | 0.3406940 | predicates |
| thirsty | 0.3374613 | 0.4729000 | predicates |
| throw | 0.4114707 | 0.4921587 | predicates |
| tickle | 0.4728701 | 0.4993228 | predicates |
| tiny | 0.1459575 | 0.3531058 | predicates |
| tired | 0.3302381 | 0.4703547 | predicates |
| touch | 0.3318247 | 0.4709245 | predicates |
| wait | 0.3117409 | 0.4632598 | predicates |
| wake | 0.2804384 | 0.4492670 | predicates |
| walk | 0.5175856 | 0.4997500 | predicates |
| wash | 0.4499167 | 0.4975445 | predicates |
| watch (action) | 0.3356360 | 0.4722686 | predicates |
| wet | 0.5241379 | 0.4994764 | predicates |
| white | 0.2816667 | 0.4498652 | predicates |
| windy | 0.2769048 | 0.4475223 | predicates |
| wipe | 0.3461172 | 0.4757878 | predicates |
| wish | 0.0858984 | 0.2802473 | predicates |
| work (action) | 0.3802951 | 0.4855171 | predicates |
| write | 0.2884707 | 0.4531051 | predicates |
| yellow | 0.4290805 | 0.4950037 | predicates |
| yucky | 0.5406949 | 0.4984005 | predicates |
Vocab %>%
filter(!is.na(out)) %>%
group_by(definition) %>%
summarise(
mean=mean(out),
sd=sd(out),
category = first(lexical_category)
) %>%
ggplot(aes(x=mean, fill=category)) + geom_histogram()
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.
Stick to just nouns and predicates as these are relatively clearly not grammatical items.
Vocab_short_with_ids <- Vocab %>%
filter(lexical_category == "nouns" | lexical_category == "predicates") %>%
dplyr::select(data_id, value, out, definition) %>%
pivot_wider(id_cols=data_id, names_from = "definition", values_from="out") %>%
drop_na() # drop participants with missing data
Vocab_short <- Vocab_short_with_ids %>%
dplyr::select(-"data_id") # dataset for IRT can't have IDs
nrow(Vocab_short_with_ids) == N_total - N_long - N_missing # Looks good
## n
## [1,] TRUE
I’m not going to bother with the correlation plot because I think it will be too difficult to visualize.
Complex_poly <- tetrachoric(Vocab_short)
## For i = 131 j = 58 A cell entry of 0 was replaced with correct = 0.5. Check your data!
## For i = 160 j = 58 A cell entry of 0 was replaced with correct = 0.5. Check your data!
## For i = 225 j = 58 A cell entry of 0 was replaced with correct = 0.5. Check your data!
## For i = 387 j = 58 A cell entry of 0 was replaced with correct = 0.5. Check your data!
## For i = 448 j = 445 A cell entry of 0 was replaced with correct = 0.5. Check your data!
## Warning in cor.smooth(mat): Matrix was not positive definite, smoothing was done
rho <- Complex_poly$rho
These will not run.
#pc <- princals(rho)
#plot(pc)
fa.parallel(rho, fa="fa", fm="minres", cor="poly", n.obs = 4186)
## The determinant of the smoothed correlation was zero.
## This means the objective function is not defined.
## Chi square is based upon observed residuals.
## The determinant of the smoothed correlation was zero.
## This means the objective function is not defined for the null model either.
## The Chi square is thus based upon observed correlations.
## Warning in fa.stats(r = r, f = f, phi = phi, n.obs = n.obs, np.obs = np.obs, :
## The estimated weights for the factor scores are probably incorrect. Try a
## different factor score estimation method.
## Parallel analysis suggests that the number of factors = 22 and the number of components = NA
#m1 <- mirt(Vocab_short, 1, itemtype="2PL")
#saveRDS(m1, "vocab_output/m1.rds")
m1 <- readRDS("vocab_output/m1.rds")
Looking at item misfit statistics
#itf <- itemfit(m1)
#saveRDS(itf, "vocab_output/itf.rds")
itf <- readRDS("vocab_output/itf.rds")
misfit <- itf %>% # Get labels of mis-fitting items.
filter(p.S_X2 <= .01) %>%
dplyr::select(item) %>%
as.vector()
items_good <- dplyr::select(Vocab_short, -all_of(misfit$item)) # Well fitting items
items_bad <- dplyr::select(Vocab_short, all_of(misfit$item)) # Poorly fitting items
mod_fit <- mirt(items_good, 1, "2PL", verbose=FALSE) # Calculate factor scores using only the well fitting items.
Theta <- fscores(mod_fit)
plot(itemGAM(items_bad$dog, Theta)) %>% update(main = "dog")
plot(itemGAM(items_bad$donkey,Theta)) %>% update(main = "donkey")
plot(itemGAM(items_bad$teddybear,Theta)) %>% update(main = "teddybear")
plot(itemGAM(items_bad$block,Theta)) %>% update(main = "block")
plot(itemGAM(items_bad$doll,Theta)) %>% update(main = "doll")
plot(itemGAM(items_bad$`toy (object)`,Theta)) %>% update(main = "toy (object)")
plot(itemGAM(items_bad$beans,Theta)) %>% update(main = "beans")
plot(itemGAM(items_bad$raisin,Theta)) %>% update(main = "raisin")
plot(itemGAM(items_bad$underpants,Theta)) %>% update(main = "underpants")
plot(itemGAM(items_bad$`penis*`,Theta)) %>% update(main = "penis")
plot(itemGAM(items_bad$`vagina*`,Theta)) %>% update(main = "vagina")
plot(itemGAM(items_bad$clock,Theta)) %>% update(main = "clock")
plot(itemGAM(items_bad$dish,Theta)) %>% update(main = "dish")
plot(itemGAM(items_bad$keys,Theta)) %>% update(main = "keys")
plot(itemGAM(items_bad$plate,Theta)) %>% update(main = "plate")
plot(itemGAM(items_bad$trash,Theta)) %>% update(main = "trash")
plot(itemGAM(items_bad$bathtub,Theta)) %>% update(main = "bathtub")
plot(itemGAM(items_bad$TV,Theta)) %>% update(main = "TV")
plot(itemGAM(items_bad$catch, Theta)) %>% update(main = "catch")
plot(itemGAM(items_bad$fit,Theta)) %>% update(main = "fit")
plot(itemGAM(items_bad$get,Theta)) %>% update(main = "get")
plot(itemGAM(items_bad$go,Theta)) %>% update(main = "go")
plot(itemGAM(items_bad$read,Theta)) %>% update(main = "read")
true_raw <- Vocab_short %>%
mutate(
Raw = rowSums(.[,1:478]),
Theta = fscores(m1)
) %>%
ggplot(aes(x=Theta, y=Raw)) + geom_point() + stat_smooth(method="loess") + theme_minimal()
raw_score <- Vocab_short %>%
mutate(
Raw = rowSums(.[,1:478])
) %>%
ggplot(aes(x=Raw)) + geom_histogram() + theme_minimal()
true_score <- Vocab_short %>%
mutate(
Theta = fscores(m1)
) %>%
ggplot(aes(x=Theta)) + geom_histogram() + theme_minimal()
library(patchwork)
true_raw/(true_score + raw_score)
## `geom_smooth()` using formula 'y ~ x'
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.
## `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.
coefs_2pl <- coef(m1, as.data.frame = TRUE) %>%
t() %>%
as_tibble() %>%
dplyr::select(-c(1913:1914)) %>%
pivot_longer(everything()) %>%
tidyr::separate(, col=name, into=c("item", "parameter"), sep="([.])") %>%
filter(parameter == "a1" | parameter == "d" ) %>%
pivot_wider(id_cols=item, names_from=parameter, values_from=value)
## Warning: Expected 2 pieces. Additional pieces discarded in 180 rows [41, 42,
## 43, 44, 69, 70, 71, 72, 281, 282, 283, 284, 297, 298, 299, 300, 349, 350, 351,
## 352, ...].
ggplot(coefs_2pl,
aes(x = a1, y = -d)) + # Note in the book they use -d here, I think MIRT outputs a1 and an easiness rather than a difficulty.
geom_point(alpha = .3) +
ggrepel::geom_text_repel(data = coefs_2pl,
aes(label = item), size = 3) +
xlab("Discrimination") +
ylab("Difficulty") + theme_minimal()
## Warning: ggrepel: 312 unlabeled data points (too many overlaps). Consider
## increasing max.overlaps
#ggplot(coefs_2pl, aes(x=a1, fill=lexical_category)) + geom_histogram() + theme_minimal()
#ggplot(coefs_2pl, aes(x=d, fill=lexical_category)) + geom_histogram() + theme_minimal()
These discrimination parameters look good, but I’m not crazy about the item response functions, so I will try a spline model .
#m2 <- mirt(Vocab_short, 1, "spline", technical=list(NCYCLES = 1000)) # I can increase iterations, but it just jumps around the same few values.
#saveRDS(m2, "vocab_output/m2.rds")
m2 <- readRDS("vocab_output/m2.rds")
Plot latent variables of spline model against 2PL model.
Vocab_short %>%
mutate(
Raw = rowSums(.[,1:478]),
Theta_2pl = fscores(m1)[,1],
Theta_spline = fscores(m2)[,1]
) %>%
dplyr::select("Raw", "Theta_2pl", "Theta_spline") %>%
ggpairs()
#m3 <- mirt(Vocab_short, 1, dentype="EH", technical=list(NCYCLES = 2000))
#saveRDS(m3, "vocab_output/m3.rds")
m3 <- readRDS("vocab_output/m3.rds")
Vocab_short %>%
mutate(
Raw = rowSums(.[,1:478]),
Theta_2pl = fscores(m1)[,1],
Theta_spline = fscores(m2)[,1],
Theta_EH = fscores(m3)[,1]
) %>%
dplyr::select("Raw", "Theta_2pl", "Theta_spline", "Theta_EH") %>%
ggpairs()
Compare the shape of distribution of latent variables.
(dens_plot <- Vocab_short %>%
mutate(
Theta_logit = fscores(m1)[,1], # Used MAP here, but EAP gives same results.
Theta_spline = fscores(m2)[,1],
Theta_EH = fscores(m3)[,1]
) %>%
dplyr::select("Theta_logit", "Theta_spline", "Theta_EH") %>%
pivot_longer(everything(), names_to="model", values_to="theta") %>%
ggplot(aes(x=theta, fill=model)) + geom_density(alpha = .2) +
ggtitle("Distribution of Theta"))
Theta <- matrix(seq(-4,4,.01))
m1_inf <- testinfo(m1, Theta)
#mspline_inf <- testinfo(m2, Theta)
mEH_inf <- testinfo(m3, Theta)
(info_plot <- tibble(Theta, m1_inf, mEH_inf) %>%
pivot_longer(c("m1_inf", "mEH_inf"), names_to = "LV", values_to = "Info") %>%
mutate(
model = ifelse(LV == "m1_inf", yes="2PL", no ="EH")
) %>%
ggplot(aes(x=Theta, y=Info, group=model, color=model)) + geom_line() +
ggtitle("Test Information"))
coefs_2pl <- coef(m3, as.data.frame = TRUE) %>%
t() %>%
as_tibble() %>%
dplyr::select(-c(1913:1914)) %>%
pivot_longer(everything()) %>%
tidyr::separate(, col=name, into=c("item", "parameter"), sep="([.])") %>%
filter(parameter == "a1" | parameter == "d" ) %>%
pivot_wider(id_cols=item, names_from=parameter, values_from=value)
## Warning: Expected 2 pieces. Additional pieces discarded in 180 rows [41, 42,
## 43, 44, 69, 70, 71, 72, 281, 282, 283, 284, 297, 298, 299, 300, 349, 350, 351,
## 352, ...].
ggplot(coefs_2pl,
aes(x = a1, y = -d)) + # Note in the book they use -d here, I think MIRT outputs a1 and -d
geom_point(alpha = .3) +
ggrepel::geom_text_repel(data = coefs_2pl,
aes(label = item), size = 3) +
xlab("Discrimination") +
ylab("Difficulty") + theme_minimal()
## Warning: ggrepel: 306 unlabeled data points (too many overlaps). Consider
## increasing max.overlaps
Compare this to a model with 2 dimensions.
#m4<- mirt(Vocab_short, 2, itemtype="2PL", technical=list(NCYCLES = 4000))
#saveRDS(m4, "vocab_output/m4.rds")
m4 <- readRDS("vocab_output/m4.rds")
summary(m4, "oblimin", suppress=.20)
##
## Rotation: oblimin
##
## Rotated factor loadings:
##
## F1 F2 h2
## alligator -0.858 NA 0.784
## animal -0.847 NA 0.737
## ant -0.787 NA 0.633
## bear -0.781 -0.213 0.666
## bee -0.754 -0.204 0.620
## bird -0.794 NA 0.676
## bug -0.806 NA 0.658
## bunny -0.812 NA 0.692
## butterfly -0.845 NA 0.764
## cat -0.748 NA 0.578
## chicken (animal) -0.852 NA 0.757
## cow -0.810 -0.208 0.711
## deer -0.736 -0.236 0.608
## dog -0.710 NA 0.516
## donkey -0.735 -0.261 0.621
## duck -0.770 -0.252 0.669
## elephant -0.874 NA 0.813
## fish (animal) -0.832 NA 0.727
## frog -0.858 -0.219 0.796
## giraffe -0.807 -0.266 0.735
## goose -0.752 -0.237 0.633
## hen -0.762 -0.212 0.636
## horse -0.871 NA 0.792
## kitty -0.709 NA 0.508
## lamb -0.810 -0.201 0.707
## lion -0.863 -0.216 0.803
## monkey -0.865 NA 0.798
## moose -0.718 -0.285 0.610
## mouse -0.852 NA 0.770
## owl -0.733 -0.297 0.640
## penguin -0.799 -0.206 0.690
## pig -0.868 NA 0.793
## pony -0.778 NA 0.637
## puppy -0.757 NA 0.578
## rooster -0.826 -0.232 0.749
## sheep -0.811 -0.266 0.742
## squirrel -0.808 -0.202 0.704
## teddybear -0.801 NA 0.645
## tiger -0.846 NA 0.760
## turkey -0.807 NA 0.689
## turtle -0.836 -0.231 0.765
## wolf -0.776 -0.212 0.657
## zebra -0.829 -0.274 0.776
## airplane -0.854 NA 0.761
## bicycle -0.825 NA 0.704
## boat -0.810 -0.258 0.736
## bus -0.786 NA 0.666
## car -0.811 NA 0.700
## firetruck -0.829 NA 0.710
## helicopter -0.827 NA 0.724
## motorcycle -0.827 NA 0.701
## sled -0.702 NA 0.530
## stroller -0.785 NA 0.619
## tractor -0.708 -0.240 0.570
## train -0.862 NA 0.783
## tricycle -0.781 NA 0.642
## truck -0.807 NA 0.699
## ball -0.786 -0.304 0.725
## balloon -0.821 NA 0.716
## bat -0.742 NA 0.566
## block -0.800 NA 0.675
## book -0.825 -0.217 0.739
## bubbles -0.794 -0.223 0.692
## chalk -0.786 NA 0.641
## crayon -0.877 NA 0.781
## doll -0.754 NA 0.568
## game -0.873 NA 0.766
## glue -0.835 NA 0.710
## pen -0.815 NA 0.666
## pencil -0.864 NA 0.748
## play dough -0.780 NA 0.624
## present -0.908 NA 0.833
## puzzle -0.879 NA 0.797
## story -0.876 NA 0.774
## toy (object) -0.869 NA 0.754
## apple -0.851 NA 0.767
## applesauce -0.820 NA 0.702
## banana -0.758 NA 0.611
## beans -0.790 NA 0.656
## bread -0.879 NA 0.788
## butter -0.853 NA 0.745
## cake -0.867 NA 0.761
## candy -0.793 NA 0.631
## carrots -0.902 NA 0.835
## cereal -0.847 NA 0.720
## cheerios -0.734 NA 0.563
## cheese -0.821 NA 0.718
## chicken (food) -0.877 NA 0.780
## chocolate -0.850 NA 0.728
## coffee -0.813 NA 0.678
## coke -0.625 NA 0.390
## cookie -0.826 NA 0.691
## corn -0.878 NA 0.791
## cracker -0.815 NA 0.699
## donut -0.753 NA 0.568
## drink (beverage) -0.813 NA 0.660
## egg -0.842 NA 0.731
## fish (food) -0.757 NA 0.599
## food -0.828 NA 0.684
## french fries -0.814 NA 0.661
## grapes -0.860 NA 0.763
## green beans -0.797 NA 0.664
## gum -0.702 NA 0.496
## hamburger -0.862 NA 0.744
## ice -0.790 NA 0.632
## ice cream -0.884 NA 0.787
## jello -0.778 NA 0.609
## jelly -0.867 NA 0.758
## juice -0.772 NA 0.602
## lollipop -0.715 NA 0.513
## meat -0.791 NA 0.633
## melon -0.787 NA 0.646
## milk -0.796 NA 0.659
## muffin -0.847 NA 0.749
## noodles -0.833 NA 0.712
## nuts -0.843 NA 0.725
## orange (food) -0.875 NA 0.783
## pancake -0.850 NA 0.738
## peas -0.792 NA 0.666
## peanut butter -0.843 NA 0.722
## pickle -0.794 NA 0.636
## pizza -0.862 NA 0.750
## popcorn -0.795 NA 0.634
## popsicle -0.773 NA 0.597
## potato chip -0.813 NA 0.661
## potato -0.837 NA 0.712
## pretzel -0.778 NA 0.629
## pudding -0.811 NA 0.665
## pumpkin -0.839 NA 0.732
## raisin -0.834 NA 0.719
## salt -0.843 NA 0.713
## sandwich -0.917 NA 0.841
## sauce -0.826 NA 0.694
## soda/pop -0.629 NA 0.396
## soup -0.846 NA 0.723
## spaghetti -0.868 NA 0.755
## strawberry -0.853 NA 0.762
## toast -0.813 NA 0.688
## tuna -0.772 NA 0.604
## vanilla -0.864 NA 0.758
## vitamins -0.745 NA 0.560
## water (beverage) -0.827 NA 0.703
## yogurt -0.771 -0.218 0.653
## beads -0.719 NA 0.543
## belt -0.822 NA 0.680
## bib -0.761 NA 0.604
## boots -0.784 NA 0.642
## button -0.841 NA 0.732
## coat -0.812 NA 0.671
## diaper -0.843 NA 0.716
## dress (object) -0.852 NA 0.726
## gloves -0.840 NA 0.717
## hat -0.849 NA 0.747
## jacket -0.823 NA 0.683
## jeans -0.834 NA 0.706
## mittens -0.806 NA 0.684
## necklace -0.853 NA 0.733
## pajamas -0.897 NA 0.810
## pants -0.903 NA 0.821
## scarf -0.840 NA 0.730
## shirt -0.901 NA 0.824
## shoe -0.852 NA 0.742
## shorts -0.874 NA 0.770
## slipper -0.808 NA 0.660
## sneaker -0.754 NA 0.570
## snowsuit -0.791 NA 0.631
## sock -0.704 NA 0.496
## sweater -0.691 NA 0.516
## tights -0.783 NA 0.618
## underpants -0.819 NA 0.670
## zipper -0.864 NA 0.766
## ankle -0.832 NA 0.711
## arm -0.910 NA 0.830
## belly button -0.801 NA 0.666
## buttocks/bottom* -0.836 NA 0.701
## cheek -0.844 NA 0.727
## chin -0.857 NA 0.746
## ear -0.844 NA 0.747
## eye -0.859 NA 0.744
## face -0.898 NA 0.806
## finger -0.901 NA 0.821
## foot -0.904 NA 0.816
## hair -0.898 NA 0.814
## hand -0.916 NA 0.841
## head -0.907 NA 0.824
## knee -0.835 NA 0.723
## leg -0.935 NA 0.876
## lips -0.877 NA 0.769
## mouth -0.873 NA 0.768
## nose -0.849 NA 0.749
## owie/boo boo -0.673 NA 0.454
## penis* -0.550 NA 0.317
## shoulder -0.874 NA 0.776
## toe -0.825 NA 0.698
## tongue -0.837 NA 0.712
## tooth -0.843 NA 0.714
## tummy -0.880 NA 0.774
## vagina* -0.605 NA 0.366
## basket -0.893 NA 0.804
## blanket -0.869 NA 0.755
## bottle -0.730 NA 0.532
## bowl -0.870 NA 0.764
## box -0.864 NA 0.757
## broom -0.833 NA 0.694
## brush -0.873 NA 0.765
## bucket -0.880 NA 0.784
## camera -0.906 NA 0.824
## can (object) -0.858 NA 0.736
## clock -0.795 NA 0.663
## comb -0.846 NA 0.718
## cup -0.868 NA 0.754
## dish -0.853 NA 0.729
## fork -0.905 NA 0.828
## garbage -0.802 NA 0.644
## glass -0.863 NA 0.745
## glasses -0.864 NA 0.753
## hammer -0.847 NA 0.733
## jar -0.615 NA 0.401
## keys -0.659 NA 0.436
## knife -0.909 NA 0.831
## lamp -0.859 NA 0.745
## light -0.849 NA 0.728
## medicine -0.887 NA 0.787
## money -0.841 NA 0.708
## mop -0.803 NA 0.644
## nail -0.865 NA 0.753
## napkin -0.886 NA 0.785
## paper -0.924 NA 0.854
## penny -0.805 NA 0.647
## picture -0.928 NA 0.860
## pillow -0.918 NA 0.842
## plant -0.879 NA 0.779
## plate -0.906 NA 0.824
## purse -0.821 NA 0.675
## radio -0.836 NA 0.700
## scissors -0.897 NA 0.805
## soap -0.899 NA 0.809
## spoon -0.861 NA 0.759
## tape -0.893 NA 0.798
## telephone -0.891 NA 0.795
## tissue/kleenex -0.863 NA 0.743
## toothbrush -0.889 NA 0.793
## towel -0.911 NA 0.830
## trash -0.723 NA 0.522
## tray -0.862 NA 0.746
## vacuum -0.838 NA 0.706
## walker -0.788 NA 0.620
## watch (object) -0.843 NA 0.714
## basement -0.674 NA 0.468
## bathroom -0.927 NA 0.860
## bathtub -0.847 NA 0.718
## bed -0.911 NA 0.829
## bedroom -0.910 NA 0.828
## bench -0.893 NA 0.805
## chair -0.915 NA 0.839
## closet -0.932 NA 0.869
## couch -0.893 NA 0.797
## crib -0.856 NA 0.734
## door -0.880 NA 0.775
## drawer -0.903 NA 0.814
## dryer -0.910 NA 0.829
## garage -0.875 NA 0.773
## high chair -0.825 NA 0.682
## kitchen -0.937 NA 0.877
## living room -0.898 NA 0.805
## oven -0.898 NA 0.807
## play pen -0.782 NA 0.610
## porch -0.842 NA 0.708
## potty -0.824 NA 0.680
## rocking chair -0.861 NA 0.746
## refrigerator -0.896 NA 0.802
## room -0.911 NA 0.830
## shower -0.890 NA 0.794
## sink -0.919 NA 0.844
## sofa -0.757 NA 0.573
## stairs -0.868 NA 0.753
## stove -0.834 NA 0.700
## table -0.937 NA 0.878
## TV -0.851 NA 0.723
## window -0.880 NA 0.775
## washing machine -0.848 NA 0.724
## backyard -0.837 NA 0.700
## cloud -0.856 NA 0.748
## flag -0.817 NA 0.687
## flower -0.878 NA 0.788
## garden -0.865 NA 0.752
## grass -0.898 NA 0.807
## hose -0.852 NA 0.731
## ladder -0.887 NA 0.804
## lawn mower -0.784 NA 0.632
## moon -0.767 -0.208 0.641
## pool -0.779 NA 0.609
## rain -0.906 NA 0.825
## rock -0.852 NA 0.737
## roof -0.901 NA 0.815
## sandbox -0.833 NA 0.702
## shovel -0.869 NA 0.768
## sidewalk -0.914 NA 0.836
## sky -0.826 NA 0.688
## slide (object) -0.869 NA 0.762
## snow -0.758 NA 0.603
## snowman -0.846 NA 0.735
## sprinkler -0.859 NA 0.744
## star -0.809 NA 0.686
## stick -0.869 NA 0.760
## stone -0.795 NA 0.635
## street -0.920 NA 0.846
## sun -0.884 NA 0.796
## swing (object) -0.853 NA 0.737
## tree -0.849 NA 0.751
## water (not beverage) -0.860 NA 0.749
## wind -0.883 NA 0.787
## bite -0.831 NA 0.713
## blow -0.868 NA 0.760
## break -0.902 NA 0.827
## bring -0.889 NA 0.816
## build -0.916 NA 0.842
## bump -0.826 NA 0.688
## buy -0.857 NA 0.752
## carry -0.912 NA 0.844
## catch -0.892 NA 0.813
## chase -0.855 NA 0.739
## clap -0.863 NA 0.756
## clean (action) -0.913 NA 0.844
## climb -0.926 NA 0.863
## close -0.878 NA 0.781
## cook -0.885 NA 0.786
## cover -0.909 NA 0.849
## cry -0.909 NA 0.844
## cut -0.900 NA 0.818
## dance -0.881 NA 0.783
## draw -0.873 NA 0.767
## drink (action) -0.856 NA 0.747
## drive -0.916 NA 0.846
## drop -0.922 NA 0.865
## dry (action) -0.914 NA 0.840
## dump -0.828 NA 0.687
## eat -0.876 NA 0.790
## fall -0.919 NA 0.855
## feed -0.920 NA 0.857
## find -0.939 NA 0.898
## finish -0.855 NA 0.750
## fit -0.910 NA 0.843
## fix -0.910 NA 0.834
## get -0.873 NA 0.787
## give -0.901 0.205 0.842
## go -0.755 NA 0.587
## hate -0.769 0.213 0.626
## have -0.924 NA 0.865
## hear -0.921 NA 0.859
## help -0.849 NA 0.728
## hide -0.897 NA 0.814
## hit -0.894 NA 0.824
## hold -0.915 NA 0.860
## hug -0.884 NA 0.796
## hurry -0.877 0.210 0.801
## jump -0.905 NA 0.825
## kick -0.882 NA 0.794
## kiss -0.883 NA 0.806
## knock -0.843 NA 0.718
## lick -0.911 NA 0.838
## like -0.924 NA 0.866
## listen -0.893 NA 0.821
## look -0.855 0.227 0.770
## love -0.824 NA 0.696
## make -0.932 NA 0.883
## open -0.882 NA 0.790
## paint -0.878 NA 0.771
## pick -0.914 NA 0.857
## play -0.911 NA 0.844
## pour -0.909 NA 0.834
## pretend -0.876 NA 0.775
## pull -0.886 NA 0.799
## push -0.874 NA 0.775
## put -0.902 NA 0.838
## read -0.893 NA 0.798
## ride -0.917 NA 0.853
## rip -0.855 NA 0.742
## run -0.934 NA 0.878
## say -0.883 0.203 0.810
## see -0.825 0.208 0.713
## shake -0.877 NA 0.776
## share -0.902 NA 0.832
## show -0.927 NA 0.878
## sing -0.924 NA 0.865
## sit -0.847 NA 0.733
## skate -0.853 NA 0.728
## sleep -0.925 NA 0.869
## slide (action) -0.883 NA 0.781
## smile -0.891 0.204 0.823
## spill -0.923 NA 0.866
## splash -0.888 NA 0.793
## stand -0.929 NA 0.885
## stay -0.880 0.208 0.806
## stop -0.837 0.215 0.735
## sweep -0.885 NA 0.788
## swim -0.887 NA 0.786
## swing (action) -0.873 NA 0.762
## take -0.918 NA 0.867
## talk -0.912 0.215 0.866
## taste -0.897 NA 0.826
## tear -0.906 NA 0.843
## think -0.891 NA 0.818
## throw -0.925 NA 0.865
## tickle -0.823 NA 0.686
## touch -0.904 NA 0.835
## wait -0.849 0.227 0.759
## wake -0.907 NA 0.839
## walk -0.877 NA 0.774
## wash -0.912 NA 0.841
## watch (action) -0.892 NA 0.812
## wipe -0.881 NA 0.789
## wish -0.869 0.227 0.795
## work (action) -0.877 NA 0.772
## write -0.861 NA 0.764
## all gone -0.732 NA 0.536
## asleep -0.864 NA 0.754
## awake -0.896 NA 0.811
## bad -0.762 0.216 0.616
## better -0.877 NA 0.776
## big -0.897 NA 0.803
## black -0.838 NA 0.712
## blue -0.776 NA 0.632
## broken -0.885 NA 0.787
## brown -0.840 NA 0.722
## careful -0.894 NA 0.801
## clean (description) -0.919 NA 0.846
## cold -0.870 NA 0.757
## cute -0.796 NA 0.641
## dark -0.871 NA 0.759
## dirty -0.889 NA 0.791
## dry (description) -0.900 NA 0.810
## empty -0.842 NA 0.709
## fast -0.907 NA 0.823
## fine -0.850 NA 0.731
## first -0.892 NA 0.813
## full -0.896 NA 0.810
## gentle -0.781 NA 0.610
## good -0.828 NA 0.706
## green -0.819 NA 0.701
## happy -0.838 NA 0.702
## hard -0.919 NA 0.849
## heavy -0.914 NA 0.837
## high -0.890 NA 0.792
## hot -0.759 NA 0.576
## hungry -0.879 NA 0.784
## hurt -0.878 NA 0.783
## last -0.898 NA 0.827
## little (description) -0.923 NA 0.853
## long -0.920 NA 0.856
## loud -0.900 NA 0.812
## mad -0.854 NA 0.750
## naughty -0.689 NA 0.479
## new -0.898 NA 0.810
## nice -0.795 NA 0.640
## noisy -0.858 NA 0.738
## old -0.873 NA 0.766
## orange (description) -0.816 NA 0.679
## poor -0.812 NA 0.675
## pretty -0.799 NA 0.642
## quiet -0.901 NA 0.820
## red -0.822 NA 0.703
## sad -0.890 NA 0.792
## scared -0.890 NA 0.798
## sick -0.898 NA 0.815
## sleepy -0.844 NA 0.716
## slow -0.895 NA 0.811
## soft -0.872 NA 0.761
## sticky -0.860 NA 0.740
## stuck -0.797 NA 0.634
## thirsty -0.874 NA 0.771
## tiny -0.860 NA 0.741
## tired -0.914 NA 0.848
## wet -0.884 NA 0.783
## white -0.842 NA 0.715
## windy -0.875 NA 0.766
## yellow -0.776 NA 0.635
## yucky -0.582 -0.208 0.389
##
## Rotated SS loadings: 343.784 7.129
##
## Factor correlations:
##
## F1 F2
## F1 1.000 0.032
## F2 0.032 1.000
anova(m4, m1)
##
## Model 1: mirt(data = Vocab_short, model = 1, itemtype = "2PL")
## Model 2: mirt(data = Vocab_short, model = 2, itemtype = "2PL", technical = list(NCYCLES = 4000))
Vocab_short %>%
mutate(
Raw = rowSums(.[,1:478]),
Theta1 = fscores(m4)[,1],
Theta2 = fscores(m4)[,2]
) %>%
dplyr::select(Raw, Theta1, Theta2) %>%
ggpairs()
Second factor doesn’t look like it’s doing much work.
model.1 <- mirt.model('
F1 = 1 - 312
F2 = 313 - 478
COV=F1*F2')
#m5 <- mirt(Vocab_short, model.1, "2PL")
#summary(m5)
#saveRDS(m5, "vocab_output/m5.rds")
m5 <- readRDS("vocab_output/m5.rds")
anova(m5, m1)
##
## Model 1: mirt(data = Vocab_short, model = 1, itemtype = "2PL")
## Model 2: mirt(data = Vocab_short, model = model.1, itemtype = "2PL")
Vocab_short %>%
mutate(
Raw = rowSums(.[,1:478]),
Theta1 = fscores(m5)[,1],
Theta2 = fscores(m5)[,2]
) %>%
dplyr::select(Raw, Theta1, Theta2) %>%
ggpairs()
Vocab_with_predictors <- Admin %>%
dplyr::select(data_id, age, ethnicity, sex, mom_ed) %>%
mutate(
female = ifelse(sex=="Female", yes=1, no=0),
age_y = ifelse(age < 25, yes=1, no=0),
college_grad = ifelse(mom_ed %in% c("College", "Some Graduate", "Some Graduate"), yes=1, no=0)
) %>%
right_join(., Vocab_short_with_ids, by="data_id")
Vocab_with_predictors %>%
summarise(
age_missing = sum(is.na(age)),
ethnicity_missing = sum(is.na(ethnicity)), # Some ethnicity variables missing.
sex_missing = sum(is.na(sex)),
college_grad = sum(is.na(college_grad))
)
table(Vocab_with_predictors$age)
##
## 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
## 305 271 442 327 273 203 200 261 569 324 180 194 145 197 295
table(Vocab_with_predictors$ethnicity)
##
## Asian Black Other White Hispanic
## 67 222 93 2202 131
table(Vocab_with_predictors$sex)
##
## Female Male Other
## 1374 1413 0
table(Vocab_with_predictors$college_grad)
##
## 0 1
## 3154 1032
#Vocab_short2 <- data.frame(Vocab_short)
#dif <- lordif(Vocab_short2,
# Vocab_with_predictors$female,
# criterion="Chisqr",
# alpha = .01)
#saveRDS(dif, "vocab_output/dif.rds")
dif <- readRDS("vocab_output/dif.rds")
dif
## Call:
## lordif(resp.data = Vocab_short2, group = Vocab_with_predictors$female,
## criterion = "Chisqr", alpha = 0.01)
##
## Number of DIF groups: 2
##
## Number of items flagged for DIF: 111 of 478
##
## Items flagged: 8, 24, 25, 26, 28, 33, 34, 38, 39, 44, 45, 46, 47, 48, 49, 50, 51, 53, 54, 55, 56, 57, 60, 65, 66, 72, 125, 135, 144, 146, 148, 151, 155, 157, 163, 164, 168, 169, 170, 174, 175, 176, 183, 186, 192, 194, 195, 198, 200, 201, 204, 205, 210, 212, 214, 216, 217, 222, 225, 226, 230, 234, 241, 246, 250, 259, 262, 263, 269, 270, 282, 284, 285, 288, 289, 290, 295, 296, 297, 303, 305, 309, 317, 321, 324, 329, 331, 334, 337, 344, 353, 358, 360, 362, 368, 385, 387, 404, 409, 415, 418, 421, 423, 424, 429, 432, 434, 440, 441, 442, 460
##
## Number of iterations for purification: 3 of 10
##
## Detection criterion: Chisqr
##
## Threshold: alpha = 0.01
##
## item ncat chi12 chi13 chi23
## 1 1 2 0.0266 0.0673 0.4878
## 2 2 2 0.1171 0.1625 0.2776
## 3 3 2 0.7516 0.8709 0.6747
## 4 4 2 0.8788 0.2822 0.1133
## 5 5 2 0.5130 0.1179 0.0498
## 6 6 2 0.6330 0.5192 0.2980
## 7 7 2 0.4475 0.7000 0.7118
## 8 8 2 0.0000 0.0002 0.7343
## 9 9 2 0.3965 0.5430 0.4785
## 10 10 2 0.1645 0.1413 0.1592
## 11 11 2 0.0550 0.1040 0.3578
## 12 12 2 0.5432 0.7461 0.6420
## 13 13 2 0.0964 0.2507 0.9663
## 14 14 2 0.1302 0.2948 0.6961
## 15 15 2 0.0525 0.1448 0.7442
## 16 16 2 0.4042 0.5678 0.5090
## 17 17 2 0.3617 0.3204 0.2294
## 18 18 2 0.6109 0.7630 0.5953
## 19 19 2 0.0190 0.0634 0.8920
## 20 20 2 0.0178 0.0367 0.3190
## 21 21 2 0.4410 0.7275 0.8367
## 22 22 2 0.2214 0.3948 0.5464
## 23 23 2 0.7781 0.8890 0.6929
## 24 24 2 0.0001 0.0003 0.2604
## 25 25 2 0.0000 0.0001 0.5059
## 26 26 2 0.0066 0.0144 0.2949
## 27 27 2 0.0705 0.1486 0.4619
## 28 28 2 0.0001 0.0006 0.5662
## 29 29 2 0.3039 0.5675 0.7827
## 30 30 2 0.5847 0.1767 0.0751
## 31 31 2 0.6821 0.3770 0.1818
## 32 32 2 0.0252 0.0614 0.4494
## 33 33 2 0.0025 0.0100 0.7622
## 34 34 2 0.0053 0.0199 0.7995
## 35 35 2 0.1252 0.3084 0.9674
## 36 36 2 0.5152 0.7326 0.6557
## 37 37 2 0.7115 0.0750 0.0247
## 38 38 2 0.0005 0.0023 0.8544
## 39 39 2 0.0088 0.0313 0.7903
## 40 40 2 0.1459 0.3305 0.7525
## 41 41 2 0.3774 0.6350 0.7195
## 42 42 2 0.0124 0.0200 0.2117
## 43 43 2 0.2964 0.5679 0.8392
## 44 44 2 0.0023 0.0082 0.6064
## 45 45 2 0.0007 0.0029 0.6916
## 46 46 2 0.0000 0.0000 0.2070
## 47 47 2 0.0000 0.0000 0.2261
## 48 48 2 0.0003 0.0009 0.3419
## 49 49 2 0.0000 0.0000 0.3984
## 50 50 2 0.0000 0.0000 0.1480
## 51 51 2 0.0000 0.0000 0.2213
## 52 52 2 0.7488 0.8881 0.7136
## 53 53 2 0.0000 0.0000 0.1354
## 54 54 2 0.0000 0.0000 0.0705
## 55 55 2 0.0000 0.0000 0.0869
## 56 56 2 0.0002 0.0005 0.2666
## 57 57 2 0.0000 0.0000 0.6035
## 58 58 2 0.6402 0.7805 0.5986
## 59 59 2 0.4557 0.0392 0.0149
## 60 60 2 0.0000 0.0000 0.4693
## 61 61 2 0.3072 0.5920 0.9398
## 62 62 2 0.2248 0.2228 0.2162
## 63 63 2 0.2580 0.2861 0.2687
## 64 64 2 0.8294 0.8824 0.6517
## 65 65 2 0.0005 0.0005 0.0873
## 66 66 2 0.0000 0.0000 0.0649
## 67 67 2 0.1777 0.0949 0.0889
## 68 68 2 0.4196 0.5973 0.5380
## 69 69 2 0.7198 0.9373 0.9765
## 70 70 2 0.1695 0.3889 0.9675
## 71 71 2 0.8038 0.8027 0.5388
## 72 72 2 0.0015 0.0042 0.3612
## 73 73 2 0.5787 0.8435 0.8578
## 74 74 2 0.7142 0.7153 0.4641
## 75 75 2 0.1701 0.3868 0.8952
## 76 76 2 0.5404 0.7423 0.6381
## 77 77 2 0.8005 0.4493 0.2152
## 78 78 2 0.1159 0.2717 0.7131
## 79 79 2 0.3021 0.5809 0.8840
## 80 80 2 0.1755 0.1830 0.2115
## 81 81 2 0.3079 0.0445 0.0228
## 82 82 2 0.8004 0.3604 0.1597
## 83 83 2 0.4070 0.0530 0.0227
## 84 84 2 0.9430 0.8513 0.5735
## 85 85 2 0.6526 0.5937 0.3593
## 86 86 2 0.4105 0.0700 0.0312
## 87 87 2 0.0474 0.0201 0.0488
## 88 88 2 0.0922 0.2418 0.9512
## 89 89 2 0.1912 0.3387 0.4992
## 90 90 2 0.4486 0.5036 0.3718
## 91 91 2 0.0801 0.1548 0.4135
## 92 92 2 0.7874 0.2961 0.1244
## 93 93 2 0.6095 0.5136 0.3005
## 94 94 2 0.0622 0.1579 0.6442
## 95 95 2 0.0739 0.1126 0.2786
## 96 96 2 0.3679 0.2381 0.1513
## 97 97 2 0.0430 0.1188 0.6837
## 98 98 2 0.4933 0.7284 0.6852
## 99 99 2 0.1391 0.1002 0.1202
## 100 100 2 0.7857 0.9031 0.7186
## 101 101 2 0.1369 0.3249 0.8489
## 102 102 2 0.3342 0.6271 0.9823
## 103 103 2 0.1543 0.2616 0.4191
## 104 104 2 0.3485 0.6429 0.9449
## 105 105 2 0.4592 0.3271 0.1940
## 106 106 2 0.5400 0.3838 0.2147
## 107 107 2 0.3592 0.6146 0.7154
## 108 108 2 0.7845 0.8099 0.5559
## 109 109 2 0.8039 0.1311 0.0454
## 110 110 2 0.5984 0.8074 0.6980
## 111 111 2 0.9152 0.4213 0.1900
## 112 112 2 0.3711 0.6602 0.8619
## 113 113 2 0.7638 0.8752 0.6746
## 114 114 2 0.3199 0.5853 0.7750
## 115 115 2 0.4108 0.6925 0.8090
## 116 116 2 0.2022 0.4222 0.7540
## 117 117 2 0.2383 0.3984 0.5024
## 118 118 2 0.4433 0.6456 0.5918
## 119 119 2 0.9989 0.2738 0.1075
## 120 120 2 0.7058 0.3492 0.1613
## 121 121 2 0.0629 0.1766 0.9271
## 122 122 2 0.4238 0.6291 0.5921
## 123 123 2 0.3954 0.0943 0.0455
## 124 124 2 0.0618 0.1269 0.4237
## 125 125 2 0.0012 0.0042 0.4759
## 126 126 2 0.0647 0.1747 0.7827
## 127 127 2 0.1378 0.2740 0.5340
## 128 128 2 0.8804 0.7553 0.4630
## 129 129 2 0.5702 0.3737 0.1995
## 130 130 2 0.0854 0.2111 0.6963
## 131 131 2 0.0914 0.0410 0.0599
## 132 132 2 0.3352 0.5716 0.6631
## 133 133 2 0.1768 0.3334 0.5417
## 134 134 2 0.1205 0.2946 0.8549
## 135 135 2 0.0068 0.0257 0.9455
## 136 136 2 0.7898 0.4479 0.2153
## 137 137 2 0.1673 0.2007 0.2533
## 138 138 2 0.1894 0.3976 0.7264
## 139 139 2 0.7862 0.9573 0.9069
## 140 140 2 0.3328 0.1147 0.0655
## 141 141 2 0.2959 0.4794 0.5388
## 142 142 2 0.2528 0.4631 0.6304
## 143 143 2 0.7010 0.6893 0.4398
## 144 144 2 0.0000 0.0000 0.2465
## 145 145 2 0.6366 0.8407 0.7250
## 146 146 2 0.0000 0.0000 0.8395
## 147 147 2 0.2825 0.2892 0.2495
## 148 148 2 0.0003 0.0014 0.8901
## 149 149 2 0.1493 0.0647 0.0653
## 150 150 2 0.0376 0.1076 0.7098
## 151 151 2 0.0000 0.0000 0.0057
## 152 152 2 0.2857 0.2120 0.1613
## 153 153 2 0.7495 0.5190 0.2714
## 154 154 2 0.4199 0.1515 0.0772
## 155 155 2 0.0000 0.0001 0.5549
## 156 156 2 0.6282 0.8876 0.9500
## 157 157 2 0.0000 0.0000 0.2909
## 158 158 2 0.1518 0.3258 0.6637
## 159 159 2 0.8050 0.8600 0.6237
## 160 160 2 0.0568 0.0993 0.3198
## 161 161 2 0.0798 0.1137 0.2583
## 162 162 2 0.0671 0.1861 0.9226
## 163 163 2 0.0000 0.0000 0.2339
## 164 164 2 0.0001 0.0002 0.3577
## 165 165 2 0.2794 0.5288 0.7471
## 166 166 2 0.1742 0.3970 0.9758
## 167 167 2 0.0213 0.0234 0.1374
## 168 168 2 0.0000 0.0000 0.1126
## 169 169 2 0.0000 0.0000 0.6868
## 170 170 2 0.0000 0.0000 0.2321
## 171 171 2 0.2186 0.0192 0.0114
## 172 172 2 0.1721 0.3726 0.7406
## 173 173 2 0.4417 0.7374 0.8947
## 174 174 2 0.0000 0.0000 0.2456
## 175 175 2 0.0000 0.0000 0.2660
## 176 176 2 0.0006 0.0008 0.1229
## 177 177 2 0.0165 0.0159 0.1115
## 178 178 2 0.0592 0.0126 0.0228
## 179 179 2 0.1187 0.2765 0.7124
## 180 180 2 0.1554 0.1233 0.1410
## 181 181 2 0.0187 0.0469 0.4410
## 182 182 2 0.0741 0.2024 0.9433
## 183 183 2 0.0000 0.0000 0.1613
## 184 184 2 0.2201 0.3562 0.4538
## 185 185 2 0.7847 0.6828 0.4067
## 186 186 2 0.0004 0.0020 0.8502
## 187 187 2 0.0634 0.1003 0.2827
## 188 188 2 0.0156 0.0439 0.5231
## 189 189 2 0.0181 0.0612 0.9684
## 190 190 2 0.8511 0.8384 0.5733
## 191 191 2 0.0156 0.0473 0.6166
## 192 192 2 0.0000 0.0000 0.0445
## 193 193 2 0.0130 0.0456 0.9859
## 194 194 2 0.0040 0.0109 0.3846
## 195 195 2 0.0004 0.0015 0.4653
## 196 196 2 0.0498 0.1459 0.9922
## 197 197 2 0.0129 0.0451 0.8919
## 198 198 2 0.0000 0.0000 0.0429
## 199 199 2 0.0354 0.0279 0.0983
## 200 200 2 0.0026 0.0098 0.6454
## 201 201 2 0.0304 0.0031 0.0087
## 202 202 2 0.9316 0.9624 0.7925
## 203 203 2 0.0381 0.0962 0.5362
## 204 204 2 0.0000 0.0000 0.0472
## 205 205 2 0.3348 0.0138 0.0057
## 206 206 2 0.0160 0.0280 0.2446
## 207 207 2 0.0397 0.1203 0.9616
## 208 208 2 0.0134 0.0279 0.3065
## 209 209 2 0.0423 0.1123 0.6181
## 210 210 2 0.0009 0.0036 0.7090
## 211 211 2 0.8193 0.5863 0.3135
## 212 212 2 0.0013 0.0031 0.2749
## 213 213 2 0.5733 0.8039 0.7296
## 214 214 2 0.0134 0.0014 0.0082
## 215 215 2 0.7811 0.9559 0.9093
## 216 216 2 0.0016 0.0057 0.5180
## 217 217 2 0.0000 0.0000 0.1154
## 218 218 2 0.1357 0.1263 0.1668
## 219 219 2 0.6807 0.9094 0.8858
## 220 220 2 0.0441 0.1111 0.5583
## 221 221 2 0.7777 0.8553 0.6293
## 222 222 2 0.0004 0.0001 0.0081
## 223 223 2 0.6191 0.8643 0.8330
## 224 224 2 0.4885 0.7280 0.6937
## 225 225 2 0.0000 0.0000 0.4532
## 226 226 2 0.0000 0.0000 0.5346
## 227 227 2 0.3403 0.6183 0.8194
## 228 228 2 0.2969 0.4700 0.5160
## 229 229 2 0.3603 0.6578 0.9761
## 230 230 2 0.0056 0.0215 0.9153
## 231 231 2 0.7601 0.9215 0.7910
## 232 232 2 0.7053 0.1869 0.0731
## 233 233 2 0.4324 0.6624 0.6489
## 234 234 2 0.0000 0.0000 0.3371
## 235 235 2 0.0171 0.0357 0.3229
## 236 236 2 0.2871 0.4164 0.4314
## 237 237 2 0.0443 0.1317 0.9221
## 238 238 2 0.6077 0.8387 0.7663
## 239 239 2 0.6842 0.4082 0.2022
## 240 240 2 0.0788 0.2122 0.9142
## 241 241 2 0.0001 0.0004 0.8649
## 242 242 2 0.5664 0.6408 0.4538
## 243 243 2 0.0470 0.0998 0.4151
## 244 244 2 0.3247 0.5930 0.7838
## 245 245 2 0.3494 0.6454 0.9951
## 246 246 2 0.0000 0.0000 0.6509
## 247 247 2 0.9307 0.9436 0.7418
## 248 248 2 0.0418 0.1023 0.5189
## 249 249 2 0.0907 0.2282 0.7607
## 250 250 2 0.1836 0.0128 0.0084
## 251 251 2 0.2985 0.3166 0.2695
## 252 252 2 0.4481 0.4534 0.3157
## 253 253 2 0.2749 0.5501 0.9554
## 254 254 2 0.4554 0.5218 0.3884
## 255 255 2 0.9812 0.7075 0.4056
## 256 256 2 0.5209 0.4820 0.3061
## 257 257 2 0.7480 0.2012 0.0781
## 258 258 2 0.0984 0.0811 0.1300
## 259 259 2 0.0015 0.0039 0.3013
## 260 260 2 0.2585 0.3156 0.3101
## 261 261 2 0.0340 0.0861 0.5221
## 262 262 2 0.0000 0.0000 0.2421
## 263 263 2 0.0001 0.0005 0.6299
## 264 264 2 0.3344 0.3154 0.2408
## 265 265 2 0.4366 0.6972 0.7334
## 266 266 2 0.0449 0.1000 0.4451
## 267 267 2 0.6849 0.1839 0.0726
## 268 268 2 0.6215 0.6153 0.3937
## 269 269 2 0.0000 0.0000 0.6001
## 270 270 2 0.0028 0.0090 0.4962
## 271 271 2 0.0659 0.0754 0.1811
## 272 272 2 0.3203 0.4273 0.3985
## 273 273 2 0.3278 0.5699 0.6830
## 274 274 2 0.0415 0.1248 0.9328
## 275 275 2 0.0142 0.0306 0.3251
## 276 276 2 0.9249 0.9924 0.9363
## 277 277 2 0.8070 0.8497 0.6059
## 278 278 2 0.8227 0.9254 0.7461
## 279 279 2 0.1739 0.2112 0.2615
## 280 280 2 0.2475 0.5030 0.8474
## 281 281 2 0.0768 0.2051 0.8480
## 282 282 2 0.0008 0.0011 0.1349
## 283 283 2 0.2858 0.3654 0.3498
## 284 284 2 0.0027 0.0099 0.6256
## 285 285 2 0.0002 0.0008 0.8235
## 286 286 2 0.3892 0.6631 0.7771
## 287 287 2 0.7100 0.7836 0.5545
## 288 288 2 0.0000 0.0000 0.2633
## 289 289 2 0.0000 0.0000 0.7190
## 290 290 2 0.0000 0.0000 0.7221
## 291 291 2 0.0457 0.1207 0.6258
## 292 292 2 0.7380 0.8708 0.6847
## 293 293 2 0.8223 0.6474 0.3654
## 294 294 2 0.3296 0.6100 0.8451
## 295 295 2 0.0000 0.0000 0.4965
## 296 296 2 0.0054 0.0022 0.0349
## 297 297 2 0.0000 0.0000 0.7308
## 298 298 2 0.7214 0.0345 0.0102
## 299 299 2 0.0687 0.1763 0.6915
## 300 300 2 0.2689 0.4653 0.5788
## 301 301 2 0.0432 0.0880 0.3789
## 302 302 2 0.0222 0.0659 0.6474
## 303 303 2 0.0000 0.0000 0.2905
## 304 304 2 0.9967 0.4211 0.1884
## 305 305 2 0.0000 0.0000 0.2777
## 306 306 2 0.0903 0.2025 0.5685
## 307 307 2 0.0730 0.0339 0.0594
## 308 308 2 0.9839 0.7072 0.4053
## 309 309 2 0.0017 0.0063 0.5848
## 310 310 2 0.1816 0.2489 0.3181
## 311 311 2 0.6609 0.8180 0.6473
## 312 312 2 0.1195 0.2444 0.5304
## 313 313 2 0.2444 0.4203 0.5382
## 314 314 2 0.8237 0.9676 0.8988
## 315 315 2 0.0281 0.0756 0.5577
## 316 316 2 0.7130 0.9280 0.9052
## 317 317 2 0.0000 0.0000 0.3851
## 318 318 2 0.8766 0.7978 0.5132
## 319 319 2 0.6395 0.0812 0.0284
## 320 320 2 0.1090 0.0830 0.1206
## 321 321 2 0.0001 0.0001 0.0452
## 322 322 2 0.0600 0.1421 0.5447
## 323 323 2 0.0355 0.0730 0.3668
## 324 324 2 0.0010 0.0020 0.2037
## 325 325 2 0.1296 0.2216 0.3973
## 326 326 2 0.3085 0.1477 0.0949
## 327 327 2 0.6275 0.3266 0.1570
## 328 328 2 0.4085 0.5311 0.4453
## 329 329 2 0.0025 0.0095 0.7003
## 330 330 2 0.3655 0.6533 0.8569
## 331 331 2 0.0034 0.0119 0.6128
## 332 332 2 0.0459 0.0341 0.0960
## 333 333 2 0.3809 0.1567 0.0865
## 334 334 2 0.0000 0.0000 0.2349
## 335 335 2 0.6037 0.5307 0.3179
## 336 336 2 0.0147 0.0479 0.7307
## 337 337 2 0.0000 0.0000 0.2206
## 338 338 2 0.4424 0.5647 0.4572
## 339 339 2 0.1203 0.0694 0.0874
## 340 340 2 0.0420 0.1251 0.8771
## 341 341 2 0.1285 0.2950 0.7166
## 342 342 2 0.5346 0.5154 0.3323
## 343 343 2 0.1454 0.3210 0.6960
## 344 344 2 0.0000 0.0000 0.0325
## 345 345 2 0.2251 0.4505 0.7252
## 346 346 2 0.8677 0.7598 0.4701
## 347 347 2 0.8733 0.6829 0.3905
## 348 348 2 0.0462 0.0515 0.1619
## 349 349 2 0.2156 0.3572 0.4685
## 350 350 2 0.2339 0.0924 0.0674
## 351 351 2 0.7691 0.1210 0.0419
## 352 352 2 0.0294 0.0880 0.7332
## 353 353 2 0.0000 0.0000 0.1584
## 354 354 2 0.3548 0.1446 0.0827
## 355 355 2 0.6172 0.2579 0.1167
## 356 356 2 0.2951 0.2988 0.2507
## 357 357 2 0.8159 0.8779 0.6497
## 358 358 2 0.0029 0.0119 0.8985
## 359 359 2 0.6260 0.7082 0.5012
## 360 360 2 0.0007 0.0032 0.7519
## 361 361 2 0.9845 0.9411 0.7280
## 362 362 2 0.0023 0.0079 0.5451
## 363 363 2 0.8298 0.6846 0.3989
## 364 364 2 0.8945 0.8055 0.5194
## 365 365 2 0.2580 0.1502 0.1130
## 366 366 2 0.8960 0.9061 0.6712
## 367 367 2 0.6710 0.5080 0.2786
## 368 368 2 0.0037 0.0131 0.6240
## 369 369 2 0.5703 0.2811 0.1366
## 370 370 2 0.8847 0.3299 0.1383
## 371 371 2 0.2191 0.0462 0.0312
## 372 372 2 0.9515 0.6109 0.3217
## 373 373 2 0.0478 0.0823 0.2994
## 374 374 2 0.1485 0.2528 0.4155
## 375 375 2 0.0857 0.2284 0.9823
## 376 376 2 0.1042 0.2666 0.9516
## 377 377 2 0.0923 0.1731 0.4120
## 378 378 2 0.0851 0.1406 0.3276
## 379 379 2 0.4679 0.4877 0.3404
## 380 380 2 0.9600 0.9939 0.9216
## 381 381 2 0.3335 0.2766 0.2009
## 382 382 2 0.9565 0.9222 0.6901
## 383 383 2 0.5965 0.8641 0.9132
## 384 384 2 0.6203 0.1137 0.0428
## 385 385 2 0.0004 0.0021 0.9885
## 386 386 2 0.1962 0.4254 0.8432
## 387 387 2 0.0051 0.0176 0.6253
## 388 388 2 0.5390 0.6034 0.4263
## 389 389 2 0.8955 0.4012 0.1786
## 390 390 2 0.0509 0.0147 0.0313
## 391 391 2 0.3744 0.4332 0.3471
## 392 392 2 0.1750 0.3661 0.6797
## 393 393 2 0.0318 0.0921 0.6897
## 394 394 2 0.2238 0.4675 0.8405
## 395 395 2 0.5672 0.5034 0.3065
## 396 396 2 0.0921 0.1011 0.1863
## 397 397 2 0.8707 0.6509 0.3616
## 398 398 2 0.0291 0.0920 0.9202
## 399 399 2 0.5372 0.3644 0.2006
## 400 400 2 0.4096 0.0953 0.0449
## 401 401 2 0.8364 0.6353 0.3525
## 402 402 2 0.2206 0.1261 0.1041
## 403 403 2 0.8174 0.6114 0.3347
## 404 404 2 0.0000 0.0000 0.0435
## 405 405 2 0.1942 0.3795 0.6153
## 406 406 2 0.8774 0.9874 0.9686
## 407 407 2 0.8814 0.9430 0.7577
## 408 408 2 0.7405 0.6891 0.4255
## 409 409 2 0.0097 0.0091 0.0991
## 410 410 2 0.1736 0.3435 0.5927
## 411 411 2 0.6732 0.7008 0.4653
## 412 412 2 0.3861 0.6708 0.8278
## 413 413 2 0.1281 0.1790 0.2888
## 414 414 2 0.5513 0.1420 0.0596
## 415 415 2 0.0014 0.0036 0.3065
## 416 416 2 0.4418 0.7393 0.9104
## 417 417 2 0.8449 0.6712 0.3836
## 418 418 2 0.0024 0.0065 0.3620
## 419 419 2 0.1674 0.1874 0.2297
## 420 420 2 0.5368 0.8252 0.9568
## 421 421 2 0.0041 0.0096 0.3045
## 422 422 2 0.0464 0.0723 0.2568
## 423 423 2 0.0009 0.0012 0.1275
## 424 424 2 0.0034 0.0095 0.3953
## 425 425 2 0.1539 0.3418 0.7351
## 426 426 2 0.0635 0.0739 0.1836
## 427 427 2 0.1225 0.1802 0.3073
## 428 428 2 0.5161 0.7914 0.8299
## 429 429 2 0.0030 0.0082 0.3776
## 430 430 2 0.0914 0.1897 0.4905
## 431 431 2 0.4310 0.7324 0.9584
## 432 432 2 0.0001 0.0002 0.1516
## 433 433 2 0.3358 0.1626 0.0999
## 434 434 2 0.0000 0.0002 0.7290
## 435 435 2 0.9966 0.2417 0.0919
## 436 436 2 0.0187 0.0307 0.2299
## 437 437 2 0.5523 0.5222 0.3307
## 438 438 2 0.5612 0.7273 0.5843
## 439 439 2 0.0739 0.1493 0.4352
## 440 440 2 0.0005 0.0021 0.6279
## 441 441 2 0.0004 0.0006 0.1498
## 442 442 2 0.0013 0.0028 0.2264
## 443 443 2 0.0528 0.0347 0.0848
## 444 444 2 0.9557 0.3457 0.1453
## 445 445 2 0.4518 0.1748 0.0874
## 446 446 2 0.1811 0.1593 0.1697
## 447 447 2 0.0591 0.1556 0.6910
## 448 448 2 0.8871 0.9691 0.8363
## 449 449 2 0.7455 0.8322 0.6088
## 450 450 2 0.3165 0.5978 0.8734
## 451 451 2 0.0123 0.0183 0.1875
## 452 452 2 0.9642 0.9433 0.7348
## 453 453 2 0.4879 0.6769 0.5843
## 454 454 2 0.5848 0.1398 0.0565
## 455 455 2 0.2701 0.4563 0.5526
## 456 456 2 0.0952 0.2457 0.8789
## 457 457 2 0.9442 0.0574 0.0169
## 458 458 2 0.7454 0.5484 0.2951
## 459 459 2 0.4778 0.6696 0.5849
## 460 460 2 0.0000 0.0000 0.0341
## 461 461 2 0.0608 0.0407 0.0893
## 462 462 2 0.1022 0.2031 0.4721
## 463 463 2 0.4678 0.7394 0.7818
## 464 464 2 0.8959 0.5430 0.2725
## 465 465 2 0.2782 0.3377 0.3184
## 466 466 2 0.0151 0.0428 0.5271
## 467 467 2 0.2540 0.4811 0.6867
## 468 468 2 0.2151 0.0244 0.0152
## 469 469 2 0.8160 0.6523 0.3710
## 470 470 2 0.1365 0.3097 0.7210
## 471 471 2 0.9864 0.1457 0.0497
## 472 472 2 0.4063 0.0280 0.0110
## 473 473 2 0.0681 0.0625 0.1364
## 474 474 2 0.0397 0.0298 0.0946
## 475 475 2 0.9568 0.9799 0.8462
## 476 476 2 0.2046 0.2540 0.2874
## 477 477 2 0.3030 0.5583 0.7460
## 478 478 2 0.7591 0.0893 0.0295
plot(dif)
A lot o items were flagged, but given the relatively small values of the difference between initial and pure variables I’m not overly concerned.
#dif2 <- lordif(Vocab_short2,
# Vocab_with_predictors$college_grad,
# criterion="Chisqr",
# alpha = .01)
#saveRDS(dif2, "vocab_output/dif2.rds")
dif2 <- readRDS("vocab_output/dif2.rds")
plot(dif2)