its (version 0.1.1)

its-file: File Operations for Irregular Time-Series Objects

Description

File read and write operations for objects of class "its".

Usage

readcsvIts(filename,informat=its.format(),outformat=its.format(),tz="",
usetz=FALSE,header=TRUE,...)
writecsvIts(x,filename,format=its.format(),tz="",usetz=FALSE,col.names=NA,
sep=",",...)

Arguments

filename
filename
x
an object of class "its"
format, informat, outformat, tz, usetz
formatting related arguments, see format.POSIXct.
header
col.names, sep
...
further arguments passed to or from other methods: for readcsv.its passed to read.csv; for writecsv.its passed to write.table

Value

  • For readcsv.its an object of class "its".

Details

readcsv.its reads from a .csv file to an irregular time-series object. writecsv.its write an irregular time-series object to a text file.

See Also

ts, POSIXct, its-file, its-lags its-join its-times its-subset its-fin its-disp its-info its-cumdif its-arith

Examples

Run this code
a <- matrix(c(seq(by=24*60*60,length=20),1:20,41:60),nrow=20,ncol=3)
b <- as.its(a)
fname <- tempfile()
# To write an irregular time-series object to a file one might use
writecsvIts(b,filename=fname)
# To read an irregular time-series object from a file one might use
readcsvIts(filename=fname,informat=its.format())
unlink(fname)

Run the code above in your browser using DataLab