采用Bursts封装的R中的突发检测(Kleinberg)

时间:2013-10-30 17:02:21

标签: r

> library(bursts)
> par(mfrow=c(2,1))
> offsets <- c(seq(0, 400, 100), seq(410, 450, 5), seq(451, 470, 2),
+              seq(480, 600, 5), 700, seq(710, 800, 5), 900, 1000)
> bursts <- kleinberg(offsets)
> plot(offsets)
> plot(bursts)

遵循bursts包的演示代码。我在下面绘制了一个图,我无法将突发结果与原始数据联系起来。爆裂图表明在400+时有一个高水平爆发,我只是看不到原始图中的任何爆发。任何人都可以帮我理解如何阅读爆裂情节吗?

enter image description here

1 个答案:

答案 0 :(得分:1)

您正在将索引绘制为x,将偏移量绘制为y,但我认为您应该切换它们。试试这个:

plot(offsets,1:length(offsets))

enter image description here