Re: [R] Object and Classes ?

2009-05-14 Thread myshare
R.  For example summary.glm for > summary(x) where x is of class glm. > > > myshare wrote: >> >> I found a tutorial for creating classes using generic functions ? S3 >> way ! It was short description so I couldn't grok in full its >> usage ... So far so good,

Re: [R] is.variable ? is.initialized ?

2009-05-14 Thread myshare
thanx, I forgot something how then do you check if u have something like this : exists("xxx$array") this does not seem to work !! ;\ On Thu, May 14, 2009 at 11:26 PM, Rolf Turner wrote: > > On 15/05/2009, at 11:19 AM, myshare wrote: > >> hi guys, >> >

[R] is.variable ? is.initialized ?

2009-05-14 Thread myshare
hi guys, How do you check if variable is initialized/created, tried : is.nan(xxx) is.null(xxx) is.na(xxx) exists(xxx) all of them return : Error: object "xxx" not found I need true/false result ? thanx __ R-help@r-project.org mailing list https://s

[R] plotting multiple data sources

2009-05-13 Thread myshare
hi, Excuse me asking three questions in a row for a day, but I had collected those questions as I'm still experimenting with R. This one is how do you compose plots with alot of data in one graph. First what I currently do is after i generated all the data I need to plot.. let say 5-6 arrays I do

[R] Object and Classes ?

2009-05-13 Thread myshare
I found a tutorial for creating classes using generic functions ? S3 way ! It was short description so I couldn't grok in full its usage ... So far so good, what i currently do is something like this : Blah <- function(data,...) UseMethod('Blah') Blah.default <- function( .. ) { self = ..

[R] Dates and arrays

2009-05-13 Thread myshare
hi, I have a and data frame with date-column and some other columns. My first question is what is the fastest way to get the index of an array if I know the value f.e > x = c(4,5,6,7,8) so i know the value is 6.. i.e. the index is 3. What I currently do is loop over the array, I was thinking if