Problem in the formula of Standard Deviation

14 views
Skip to first unread message

Irshad Mujawar

unread,
May 19, 2015, 5:43:50 AM5/19/15
to mirt-p...@googlegroups.com
Hello Phil,

While using itemfit() function for missing data, the output showed some extra entities with SD_ character below the item fit statistics. Assuming that it stand for stand deviation I compared the entities with the formula, looks like something is not right.


ave[pick1, pick2] <- SD[pick1, pick2] <- 0

Here you are calculating sum(Xi), which is fine
       
 for (i in 1L:impute) ave[pick1, pick2] <- ave[pick1,
            pick2
] + collect[[i]][pick1, pick2]

Here it is average  ( sum(Xi)/n) which is also fine.


        ave[pick1, pick2] <- ave[pick1, pick2]/impute

But here, you are only taking square over the difference (ave(Xi)  - Xi), where is the sum over i part ?

        for (i in 1L:impute) SD[pick1, pick2] <- (ave[pick1,
            pick2
] - collect[[i]][pick1, pick2])^2


        SD[pick1, pick2] <- sqrt(SD[pick1, pick2]/impute)







Thanking you,

Irshad 

Phil Chalmers

unread,
May 19, 2015, 7:37:08 AM5/19/15
to Irshad Mujawar, mirt-package
You're right, that looks to be a typo. Fixed on the dev. Thanks for the report.

Phil

--
You received this message because you are subscribed to the Google Groups "mirt-package" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mirt-package...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages