R-alpha: "[<-"

Paul Gilbert (pgilbert@bank-banque-canada.ca)
Mon, 10 Jun 1996 08:45:30 -0400


Date: Mon, 10 Jun 1996 08:45:30 -0400
From: pgilbert@bank-banque-canada.ca (Paul Gilbert)
To: r-testers@stat.math.ethz.ch
Subject: R-alpha: "[<-"
Message-Id: <96Jun10.084715edt.29446@mailgate.bank-banque-canada.ca>


I'm still having a lot of difficulty because "[<-" does not strip out
my tframe attribute. I thought I might get around the problem by
redefining "[<-":

assign("prim.bracket", get("[<-"))
assign("[<-", function(x, v){attr(x,"tframe") <- NULL;
                             prim.bracket(x) <- v; x})

which works in S, but in R (0.9) I get

> a <-1:3
> a[2] <- 5
Error in [<-(c(1, 2, 3), 2, 5) : unused argument to function


Any suggestions?

Paul
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
r-testers mailing list -- To (un)subscribe, send
subscribe	or	unsubscribe
(in the "body", not the subject !)  To: r-testers-request@stat.math.ethz.ch
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-