5
我似乎發現單變量Ripley的K點模式分析的結果存在差異(圖1)。首先,我生成一個1x1的統一點網格,以查看我的R腳本是否產生邏輯結果(圖2)。研究區域爲20x40(圖2)。給定完全一致的數據,我不希望在任何搜索距離(r)處看到任何隨機或聚類點模式。附加的腳本用於生成這些結果。在這些受控條件下,爲什麼只有一個統一的點模式才能看到聚類和CSR?如何解釋統一空間數據中的CSR和聚類?
require(spatstat)
require(maptools)
require(splancs)
# Local Variables
flower = 0
year = 2013
# Read the shapefile
sdata = readShapePoints("C:/temp/sample_final.shp") #Read the shapefile
data = sdata[sdata$flow_new == flower,] # subset only flowering plants
data2 = data[data$year == year,] # subset flowering plants at year X
data.frame(data2) # Check the data
# Get the ripras estimate of area based on the study area measurements
gapdata = readShapePoints("C:/temp/study_area_boundary.shp") #Read the shapefile
whole = coordinates(gapdata) # get just the coords, excluding other data
win = convexhull.xy(whole) # Ripras will determine a good bounding polygon for the points (usually a variant of Convex Hull)
plot(win)
# Converting to PPP
points = coordinates(data2) # get just the coords, excluding other data
ppp = as.ppp(points, win) # Convert the points into the spatstat format
data.check = data.frame(ppp) # Check the format of the ppp data
summary(ppp) # General info about the created ppp object
plot(ppp) # Visually check the points and bounding area
# Now run the ppa
L.Env.ppp = envelope(ppp, Lest, nsim = 1000, correction = "best", rank =1)
plot(L.Env.ppp, main = "Uniform Test")
abline(v=(seq(1:12)), lty="dotted")
圖1
分析結果
圖2
均勻點和窗
這些點是*定期*分散(有時也稱爲*超分散*)。儘管在口語意義上它們是統一的,但它們的基本點過程並不統一:如果是這樣的話,點對的間隔可能會少於一個單位! Ripley's K的表現完全按照它旨在吸引人們注意距離均勻性的短距離偏差。 (順便說一句,你的構建和說明問題的答案爲+1)。 –
太好了,謝謝你的有見地的信息@Josh! – Borealis
噢好。很高興這有幫助。 –