Skip to content
Prev 21912 / 29559 Next

Space-time movement Trajectory on a hovmoller plot

Hi Navinder

You are starting a new thread here so I guess it is somewhat impolite of you to sort of requesting help from Oscar by including him on CC (so I have deleted from the CC).

Also please provide some code. Don't expect that people will respond to your questions if they have to do more involved work in order to show how to do the job.

The easiest answer from me to your question is to use some of the methods that Oscar and I already have shown you. Since a hovmoller diagram is based on the lattice functions contourplot() and levelplot() then you can use something like

hovmoller() + xyplot().

Yes that is easy. In any case here is an example from the man page of hovmoller():

library(rasterVis)
library(latticeExtra)
library(zoo)

url <- "ftp://ftp.wiley.com/public/sci_tech_med/spatio_temporal_data/"
sst.dat = read.table(paste(url, "SST011970_032003.dat", sep=''), header = FALSE) 
sst.ll = read.table(paste(url, "SSTlonlat.dat", sep=''), header = FALSE)

spSST <- SpatialPointsDataFrame(sst.ll, sst.dat)
gridded(spSST) <- TRUE
proj4string(spSST) = "+proj=longlat +datum=WGS84"
SST <- brick(spSST)

idx <- seq(as.Date('1970-01-01'), as.Date('2003-03-01'), by='month')
idx <- as.yearmon(idx)
SST <- setZ(SST, idx)
names(SST) <- as.character(idx)

### dummy points
somepoints <- data.frame(Time = as.yearmon(seq(as.Date("1980-01-01"),as.Date("1990-01-01"),by="6 month")),
                         Latitude = -10:10)

hovmoller(SST, panel=panel.levelplot.raster,
          xscale.components=xscale.raster.subticks,
          interpolate=TRUE, par.settings=RdBuTheme) +
              xyplot(Time ~ Latitude, data = somepoints, pch = 19, col = "black", cex = 1)
  

Yours sincerely / Med venlig hilsen


Frede Aakmann T?gersen
Specialist, M.Sc., Ph.D.
Plant Performance & Modeling

Technology & Service Solutions
T +45 9730 5135
M +45 2547 6050
frtog at vestas.com
http://www.vestas.com

Company reg. name: Vestas Wind Systems A/S
This e-mail is subject to our e-mail disclaimer statement.
Please refer to www.vestas.com/legal/notice
If you have received this e-mail in error please contact the sender.