Hi All,
I am trying to creat a simple example byusing ipf function in R, but i
could not get it succefully...I am very new to R, does anyone could help,
to instruct me about this ipf fucntion?
 Actually, this is what I mean

                  50   | 50
              ----------------------
        33.4| 28.57 | 14.29
        33.3| 23.81 | 4.762
        33.3| 9.523 | 19.05
              ----------------------
A 3*2 matrix
raw<-matrix(c(28.571,14.286,23.809,4.762,9.523,19.049),3, 2,byrow=TRUE)
the sum of margin (the value I am setting as the target)
m<-c(33.4,50,0,33.3,50,0,33.3,50)
then call ipf function:
 fit1<-ipf(table, margins=m,start=raw,eps = 1e-04, maxits = 50, showits =
    TRUE)
I could calculate it by hand with 7 iterations, but end by I am hoping to
get R build in ipf function to get it done, what should I put "table" here?
Thanks in advance!
Mandy

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to