[R] what.is(object)

Spencer Graves spencer.graves at pdf.com
Tue May 20 18:07:34 CEST 2003


Have you considered "class", "data.classe", and "attributes"?

hth.  spencer graves

Welch, Ivo wrote:
> hi:  still experimenting.  is there a function that tells me what an S 
> object is, or how it is constructed?
> 
> s <- cor.test ( x, y );
> 
> s$estimate$name = 'correlation' ;   <-  try to rename 'cor' to 
> 'correlation' fails.  obviously, name is not a part here.
> s$newfield = c("another info field", 3.2 ) ;  <- this is not congruous
> 
> so
> 
> what.is(s)       #tells me that this is a class called htest
> what.is(s$statistic)    # helps me
> 
> would allow me to see how things are constructed.   does S contain such 
> a feature?
> 
> regards,
> 
> /iaw
> 
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help




More information about the R-help mailing list