时空K函数等值线图 [英] contour map of spatial-temporal K function

查看:76
本文介绍了时空K函数等值线图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一段时间的纬度和经度数据.我想绘制(在R或Matlab中)时空K函数的轮廓图(很像下面的图),但是不知道如何绘制.任何建议都很棒!

I have latitude and longitude point data over time. I would like to plot (in R or Matlab) a contour map of spatial-temporal K function (much like the one below), but have no idea how. Any suggestions would be great!

推荐答案

以下是使用splancs包中的stkhat函数计算时空K函数的方法.我在一个时空立方体上制作一些随机数据,然后针对最多0.3个距离单位和0.3个时间单位的空间范围计算soace-time K函数估计.

Here's how to compute space-time K-functions using the stkhat function in the splancs package. I make some random data on a space-time cube, then compute the soace-time K function estimate for a spatial range up to 0.3 distance units and 0.3 time units.

> require(splancs)
> xyt=matrix(runif(3000),ncol=3)
> poly=bboxx(spoints(c(0,1,0,1)))
> tlim=c(0,1)
> s=seq(0,.3,len=51)[-1]
> t=s
> stk = stkhat(xyt[,1:2], xyt[,3], poly, tlim, s,t)
> image(str$kst)
> require(lattice)
> image(x=stk$s, y=stk$t,z = stk$kst)

这篇关于时空K函数等值线图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆