[R] Error when running a basic joint model

Isaac Singini iluwinga at yahoo.com
Mon May 16 19:43:57 CEST 2016


Thanks Bert, I will re-check the code and send the accordingly  as soon as I have access to the laptop
Isaac

Sent from Yahoo Mail on Android 
 
  On Mon, 16 May, 2016 at 6:52 pm, Bert Gunter<bgunter.4567 at gmail.com> wrote:ge    Suggestion: When new, seek out and follow guides -- in this case, the
posting guide (below), which asks that you post your code that failed.
In this case, an obvious guess is that you have mis-specified or maybe
misspelled one or more of your modeling variables in the call, but
without the code, one can't tell.

Cheers,
Bert


Bert Gunter

"The trouble with having an open mind is that people keep coming along
and sticking things into it."
-- Opus (aka Berkeley Breathed in his "Bloom County" comic strip )


On Mon, May 16, 2016 at 8:54 AM, Isaac Singini via R-help
<r-help at r-project.org> wrote:
> Dear All
> I have the following two datasets for joint modeling the survival and longitudinal data. However when I run the joint model I get the following error. I am new to R, may someone assist
>
> Error in `[.data.frame`(lmeObject$data, all.vars(TermsX)) :  undefined columns selected
>
> Data structure  for the longitudinal analysis is:
> str(cd4long)
> 'data.frame':  464 obs. of  6 variables:
>  $ id1      : int  1011555 1011555 1011555 1011555 1011558 1011558 1011558 1011558 1011568 1011568 ...
>  $ week      : int  2 4 6 12 2 4 6 12 2 4 ...
>  $ cd4countwk: int  241 137 325 283 235 219 634 465 111 316 ...
>  $ pred      : Factor w/ 2 levels "Placebo","Prednisolone": 2 2 2 2 2 2 2 2 2 2 ...
>  $ outcome  : int  0 0 0 0 0 0 0 0 0 0 ...
>  $ surv4    : int  1137 1137 1137 1137 1097 1097 1097 1097 1129 1129 ..
>
> Data structure  for the survival analysis is as
> 'data.frame':  116 obs. of  6 variables:
>  $ id1      : int  1011555 1011558 1011568 1011575 1011577 1011581 1011592 1011957 1011961 1011964 ...
>  $ week      : int  0 0 0 0 0 0 0 0 0 0 ...
>  $ cd4countwk: int  241 235 111 68 146 516 150 64 13 220 ...
>  $ outcome  : int  0 0 0 0 0 0 0 0 0 0 ...
>  $ surv4    : int  1137 1097 1129 1099 634 1137 1100 729 731 736 ...
>  $ pred      : int  1 1 1 0 1 1 0 1 0 0 …
>
>
> Thanks
> Isaac
> ______________________________________________
> R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see
> 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.  

	[[alternative HTML version deleted]]



More information about the R-help mailing list