Displaying 2 results from an estimated 2 matches for "ag15".
Did you mean:
a15
2012 Feb 17
6
convert zoo object to "standard" R object so I can plot and output to csv file
...- read.zoo(text = Lines, index = 1:2, FUN = toChron)
# 1 minute spline fit
m1 <- times("00:01:00")
g <- seq(trunc(start(z), m1), end(z), by = m1)
na.spline(z, xout = g) # this did what I want but what is the vector name?
# 15 minute aggregates
m15 <- times("00:15:00")
ag15 <- aggregate(z, trunc(time(z), m15), mean)
the results of the na.spline(z, xout = g) function below
(10/11/11 23:30:00) (10/11/11 23:31:00) (10/11/11 23:32:00) (10/11/11
23:33:00) (10/11/11 23:34:00) (10/11/11 23:35:00)
432.2189 432.2950 432.3869
432...
2012 Feb 18
2
still need read.zoo command help
...format="%m/%d/%Y %H:%M:%S",
tz="",
FUN=NULL,
regular=FALSE,
header=FALSE,
sep=",",
index.column=1)
library(zoo)
library(chron)
#this code from Gabor Grothendieck - thanks
# 15 minute aggregate averages
m15 <- times("00:15:00")
ag15 <- aggregate(z, trunc(time(z), m15), mean)
write.zoo(ag15,file="ITPower15minv2.txt",index.name="Time",row.names=FALSE,col.names=FALSE)
# this may also have a problem.
#2011-10-11 2011-10-11 is all that is written in the file
#data in the "Kevin-0-comma-ITPower.txt sta...