Hi Arun, thank you. I am well.

Yes, that worked perfectly.

Irucka


<-----Original Message-----> 
>From: arun [smartpink111@yahoo.com]
>Sent: 5/8/2013 11:39:54 AM
>To: iruckaE@mail2world.com
>Cc: r-help@r-project.org
>Subject: Re: chronological season results assistance
>
>
>
>Hi,
>I am fine.  Hope are you too.
>
>Try this:
>funFluxSumSeason <- function(DF, FUN = sum){
> month <- as.integer(format(DF$Date, format="%m"))
> year <- format(DF$Date, format="%Y")
> DF$season<- NA
> DF$season[month %in% 10:12] <- paste(year[month %in% 10:12], "Fall")
> DF$season[month %in% 1:3] <- paste(year[month %in% 1:3], "Winter")
> DF$season[month %in% 4:6] <- paste(year[month %in% 4:6], "Spring")
> DF$season[month %in% 7:9] <- paste(year[month %in% 7:9], "Summer")
> res1<-aggregate(FluxDay ~ season, data=DF, FUN = FUN) # changed here
>res1<-res[order(factor(gsub("\\d+\\s+","",res1[,1]),levels=c("Winter","
Spring","Summer","Fall"))),]
>res2<-res1[order(gsub("\\s+.*","",res1[,1])),]
>row.names(res2)<- 1:nrow(res2)
>res2
> }
>funFluxSumSeason(DailyFluxSeason,sum)
>#        season   FluxDay
>#1    2000 Fall  2897.790
>#2  2001 Winter  7551.095
>#3  2001 Spring  4062.394
>#4  2001 Summer  4386.394
>#5    2001 Fall  2148.480
>#6  2002 Winter  5887.516
>#7  2002 Spring  4551.710
>#8  2002 Summer  5159.071
>#9    2002 Fall 10946.064
>#10 2003 Winter 20223.513
>#11 2003 Spring 14275.783
>#12 2003 Summer 16653.662
>#13   2003 Fall 13901.042
>#14 2004 Winter 13396.535
>#15 2004 Spring 10918.103
>#16 2004 Summer 37343.184
>A.K.
>________________________________
>From: Irucka Embry <iruckaE@mail2world.com>
>To: smartpink111@yahoo.com 
>Cc: r-help@r-project.org 
>Sent: Wednesday, May 8, 2013 12:18 PM
>Subject: Re: chronological season results assistance
>
>
>
>Hi Arun, how are you?
>
>Thank you for your assistance. I'm sorry, but I made a mistake in what
I was seeking.
>
>For this example, this is how I would like the results to look:
>
>2000 Fall
>2001 Winter
>2001 Spring
>2001 Summer
>2001 Fall
>2002 Winter
>2002 Spring
>2002 Summer
>2002 Fall
>2003 Winter
>2003 Spring
>2003 Summer
>2003 Fall
>2004 Winter
>2004 Spring
>2004 Summer
>
>Thank you Arun.
>
>Irucka 


<span id=m2wTl><p><font face="Arial, Helvetica, sans-serif" size="2" style="font-size:13.5px">_______________________________________________________________<BR>Get the Free email that has everyone talking at <a href=http://www.mail2world.com target=new>http://www.mail2world.com</a><br>  <font color=#999999>Unlimited Email Storage &#150; POP3 &#150; Calendar &#150; SMS &#150; Translator &#150; Much More!</font></font></span>
	[[alternative HTML version deleted]]

