sumsmnw12 {lazy.irt} | R Documentation |
Distribution of the Weighted Sum of Two Independent Scored Multinomial Distributions
sumsmnw12(p1, p2, w2 = 1, eps = 1e-08, print = 0)
p1 |
Probability of the fist random variable |
p2 |
Probability of the second random variable |
w2 |
Integer weight to the second random variable |
eps |
small number |
print |
= 1 to print result |
This program calculats the distrobution of
X12 = X1 + w2 X2
where
Xi is distributed as Scored Multinomial with pi, i=1,2.
That is, this program calculates the probability that
p12[a] = Pr( X12 = a ) , a=0,1,..., n12=(n1-1)+w2*(n2-1)
Note
length(pi) = ni = #' of categories of the i-th r.v.
= mi + 1 where mi is the max score of the i-th r.v.
A matrix of (score, prob)
Mayekawa, S., & Arai, S. (2008). Distribution of the Sum of Scored Multinomial Random Variables and Its Application to the Item Response Theory. In K. Shigemasu, A. Okada, T.Imaizumi, & T. Hoshino (Eds.) New Trends in Psychometrics. Tokyo: University Academic Press.
sumsmnw12( 1:3, 1:2, 2, print=1 )