seg<- graph(c(1,2,
2,3,
2,4,
4,5,
5,6,
5,7), directed = FALSE)
name_stat<- c("Paris", "2", "Meaux", "Melun", "5", "Nemours", "Sens")
seg<- set.vertex.attribute(seg, "name", V(seg), name_stat)
# we need some data to create the object of class "Tree"
seg_data<- matrix(rnorm(10*7), 10, 7)
colnames(seg_data)<- name_stat
tobj<- Tree(seg, seg_data[,c("Paris", "Meaux", "Melun", "Nemours", "Sens")])
# create the neighborhood of order one and call the function "is_identifiable"
nobj<- Neighborhood()
nobj<- subset(nobj, 1, seg, U_bar=getNoDataNodes(tobj))
is_identifiable(nobj, tobj)
nobj<- subset(nobj, 2, seg, U_bar=getNoDataNodes(tobj))
is_identifiable(nobj, tobj)
# See also Vignette "Subsets and Coordinates"
Run the code above in your browser using DataLab