1 |
zgrid |
|
xmin |
|
xmax |
|
ymin |
|
ymax |
|
lonvec |
|
latvec |
|
datax |
|
sigma |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | ##---- Should be DIRECTLY executable !! ----
##-- ==> Define data, use random,
##-- or do help(data=index) for the standard data sets.
## The function is currently defined as
function (zgrid = zgrid, xmin = NULL, xmax = NULL, ymin = NULL,
ymax = NULL, lonvec = NULL, latvec = NULL, datax = vec, sigma = 2)
{
vec = as.numeric(datax)
data.lon = as.numeric(vec[8])
data.lat = as.numeric(vec[9])
data.sst = as.numeric(vec[11])
lat = latvec
lon = lonvec
xmin = data.lon - 3
xmax = data.lon + 3
ymin = data.lat - 3
ymax = data.lat + 3
bxlim = c(xmin, xmax)
bylim = c(ymin, ymax)
blon = which(lon >= bxlim[1] & lon <= bxlim[2])
blat = which(lat >= bylim[1] & lat <= bylim[2])
bout = zgrid[blon, blat]
lout = zgrid * 0
lout[blon, blat] = like.sst(bout, datax = data.sst, sigma = sigma)
lout
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.