[R] Contour plot with time on X-axis (day) and Y-axis (hours)
xavier.bodin at univ-savoie.fr
Fri Jan 7 14:15:00 CET 2011
I'd like to graphically represent an hourly temperature timeseries (
http://r.789695.n4.nabble.com/file/n3179098/data.csv data.csv , and see
below for pre-process of the data) with the R functions image + contour. To
do that I wrote that script (
http://r.789695.n4.nabble.com/file/n3179098/Timetemp.r Timetemp.r ) which
- creates x-axis, a vector which will contain the days,
- creates y-axis, a vector which will contain the hours of the day,
- creates the z-matrix, which has x columns and y rows.
This works fine, except that I have some troubles with the time format : I
can't set a date (day/month/year) to the x-axis of the resulting graph.
Does anyone knows where the pb is ?
||| Pre-process of data.csv:
data <- na.omit(read.csv("data.csv", header = T, sep = ",", dec = "."))
data <- data[,-1]
data[] <- strptime(data[], "%m/%d/%y %I:%M:%S %p", tz =
View this message in context: http://r.789695.n4.nabble.com/Contour-plot-with-time-on-X-axis-day-and-Y-axis-hours-tp3179098p3179098.html
Sent from the R help mailing list archive at Nabble.com.
More information about the R-help