# NOT RUN {
# }
# NOT RUN {
set.seed(123)
fevent=c(round(abs(rnorm(20,mean=7,sd=5))*1000),round(abs(rnorm(10,mean=8,sd=1))*1000))
ff=kdffreq(fevent,bandwidth = 1000, nbboot=10)
# Estimate the frequency of armed conflicts from 1946 to 2014
# Data from the The Uppsala Conflict Data Program (UCDP) available at: https://www.prio.org
dat=read.csv('http://ucdp.uu.se/downloads/ucdpprio/ucdp-prio-acd-4-2016.csv')
res=kdffreq(dat$Year,bandwidth = "bw.ucv", nbboot=1000, up = 1946, lo = 2014, interval=1, pseudo=T)
plot(res, ylab="# armed conflict/year")
# }
Run the code above in your browser using DataLab