Skip to content
Prev 32276 / 398506 Next

survit function and cox model with frailty

Giacomo  -

I'm stumped.  Again, I have never had occasion to use the
survival package myself and I am just looking for syntax
irregularities in the code you show.  The new error message
"Error in x2 %*% coef" is suggestive.  Do take a look at
coef(model1) to see if there is something irregular there.
You might print temp out to the screen to see that x2 has
the exepcted value.  Could the original data's data frame
have changed between the time  model1  was created and the
time  survfit() is run on it ?

(I've had SO much difficulty in the past with alternating
commas and decimal points that I would have defined x2 as
  x2 = rep(1.5, 5).)

I reassure you that you CAN get to the bottom of this.
I think you're making progress.  One step going forward
might be to look at  help("model.frame"), since that's
what causes the initial error message, and think about
how the arguments get matched in  survfit().

Aaaah.  Here's one more thing you could try.  Give the
new data frame of dimensions 5 x 6 some other name than
"temp" and try again.  I see that the variable name "temp"
is already used in survfit() for something else.  Again,
this is just a guess.  Unfortunately, the package code
is very complex.

-  tom blackwell  -  u michigan medical school  -  ann arbor  -
On Mon, 19 May 2003 gc4 at duke.edu wrote: