[Rd] Last Call: Who says this is not a bug in delete.response()?

From: Paul Johnson <pauljohn32_at_gmail.com>
Date: Tue, 24 Jan 2012 22:40:48 -0600


On January 5, I posted here concerning this issue (https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=14767), and I have not heard any answers from people who think this is not a bug, or a simple accident in the delete.response function.

The output from delete.response on a terms object alters the formula by removing the dependent variable. It removes the response from the
"variables" attribute and it changes the response attribute from 1 to
0. The response is removed from "predvars"

But it leaves the name of the dependent variable first in the in
"dataClasses" attribute. I believe delete.response should be fixed, and if
I'm wrong, I wish one of you would tell me. Otherwise, I will ask Prof. Ripley to re-open the bug report.

This is an important API question, since functions that use regression models (in my opinion) ought to be able to count on delete.response to leave behind a dataClasses attribute that no longer includes the response.

If we could count on that, then, some methods that work with fitted regressions could work more easily. For example, the work in termplot with variables "carrier" and "carrier.terms" would be unnecessary, since the column names of
"dataClasses" would be, exactly, the carrier.name vector and the data
type information
of those variables would eliminate a lot of fancy footwork one has to do in order
to calculate predicted values.

-- 
Paul E. Johnson
Professor, Political Science
1541 Lilac Lane, Room 504
University of Kansas

______________________________________________
R-devel_at_r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel
Received on Wed 25 Jan 2012 - 04:42:42 GMT

This quarter's messages: by month, or sorted: [ by date ] [ by thread ] [ by subject ] [ by author ]

All messages

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Wed 25 Jan 2012 - 10:30:11 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.

list of date sections of archive