Emilie Berthiaume wrote:
> Hi,
> 
> I'm a SAS user trying to convert myself to R but I still have problems with 
> some 

pretty simple commands.
> 
> First I wanted to add up a number of red-tailed hawks seen per day (

julian day) per year.  So I tried:
> 
> RTyrday <- tapply(RThr,list(year,julian),sum)

Try:

RT <- as.data.frame.table(RTyrday)


> 
> And then I tried the following regression:
> 
> mod1 <-  glm(RTyrday~julian+year, family=gaussian (link=identity),data=RT)

here it is simpler with lm()

Kjetil

> 
> Wich didn't work since my vector RTyrday and julian don't have the same 
> length.  My question is: How can I create a new data sheet with the output of 
> my function "tapply" ?  Something I could have done in SAS by giving an 
> "output out" to my "proc summary"
> 
> Thank you,
> 
> Emilie
> 
> 
> 
> Emilie Berthiaume
> Graduate Student
> Biology Department
> Sherbooke University
> Sherbrooke, Québec
> CANADA
> 
> [EMAIL PROTECTED]
>       [[alternative HTML version deleted]]
> 
> 
> 
> ------------------------------------------------------------------------
> 
> ______________________________________________
> [email protected] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Reply via email to