Bug 15308 - Wishlist: Subscripting a terms object and predvars
Summary: Wishlist: Subscripting a terms object and predvars
Alias: None
Product: R
Classification: Unclassified
Component: Wishlist (show other bugs)
Version: R 3.0.0
Hardware: Other Linux
: P5 enhancement
Assignee: R-core
Depends on:
Reported: 2013-05-07 22:23 UTC by Terry Therneau
Modified: 2013-05-08 08:54 UTC (History)
0 users

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Terry Therneau 2013-05-07 22:23:15 UTC
I commonly subscript the terms object in the survival package, most often to remove "cluster" or "strata" before calling model.matrix.  This action removes the dataClasses and predvars attributes.

I have special code to work around this at the moment, but it would be useful if these were retained.  I'm currently fixing a bug in survfit.coxph whose root is an error in my workaround.

Terry T.
Comment 1 Brian Ripley 2013-05-08 08:54:07 UTC
At the least we need a reproducible example, and a patch which does what you want would increase a lot the chances of getting this fixed the way you want.