Re: [R] function rep

2010-04-09 Thread Gang Liang
pr is a numeric number indeed slightly less than 66, hence, the vector generated by rep(1,pr) is of length 65 rather than 66... On Fri, Apr 9, 2010 at 1:58 PM, Covelli Paolo pcove...@tele2.it wrote: Hi, I've got the following code: p - 0.34 pb - p*100 pr - (1-p)*100 A - rep(0,pb) # a

Re: [R] help in function in R akin to macro in SAS

2010-04-06 Thread Gang Liang
A small correction. On Tue, Apr 6, 2010 at 9:43 AM, Stuart Luppescu s...@ccsr.uchicago.eduwrote: On Tue, 2010-04-06 at 09:33 -0700, Changbin Du wrote: #plot function plotxyf-function (data) { plot(data, type=mapping, labels=final$target, col=final$outcome+1,, main=Supervised: Mapping