[Rd] substitute and S4 objects

2007-03-24 Thread Franck Arnaud
Hi all, I don't understand why this does not what I expect : ## code start here ## setClass("num",representation(x="numeric")) num<-function(x) new("num",x=x) add<-function(e1,e2) { cat("Computing ",deparse(substitute(e1)),"+",deparse(substitute(e2)),"\n") [EMAIL PROTECTED]@x

[Rd] Using substitute from inside an S4 method

2006-12-13 Thread Franck Arnaud
Hi all, I don't understand why this does not what I expect : ## code start here ## setClass("num",representation(x="numeric")) num<-function(x) new("num",x=x) add<-function(e1,e2) { cat("Computing ",deparse(substitute(e1)),"+",deparse(substitute(e2)),"\n") [EMAIL PROTECTED]@x

[Rd] S3 fonctions for object of S4 class

2006-08-23 Thread Franck Arnaud
Hello ! there's a S3 method called start (and end too) to be used with objects of class ts (package stats). I am writing a S4 class for which I would like to use this function start, so that start with a ts calls the former method and start with my S4 class (called MA) calls the function I want. Fo

[Rd] Calloc : syntax error

2006-04-13 Thread Franck Arnaud
Hi, I have issue with Calloc : at the compilation step, gcc tells "error : syntax error before ')' token". When I use the classical C calloc... free, everything's fine. Here's the part of code : a = (double*) Calloc(*n,sizeof(double)); when i remove this line or replace it with the calloc, it's ok