[R] REPLACE and REMOVE fns

From: Tina Robles <tina.robles_at_gmail.com>
Date: Wed 04 Apr 2007 - 01:36:40 GMT


I want to use the replace function on "R_Jeter_04_post" (see attached) so that S=1, D=1, T=1, HR=1, O=0, K=0, E=0, FC=0, and W,IW,and HP are removed, so that i have a simple list of 1's and 0's.

I understand that I need to use the command "replace(x,list,values)" and "rm()" but I'm having trouble using them. (syntax errors and whatnot)

Any help would be appreciated.

-- 
Tina Robles
Graduate Assistant
Dept. Of Management Science
University of Miami

______________________________________________ R-help@stat.math.ethz.ch 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.

Received on Wed Apr 04 11:40:30 2007

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Wed 04 Apr 2007 - 08:31:12 GMT.

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