# testing to see if pairs connected by high weight edges are more likely to both be # victims than pairs connected by low weight edges. This would provide some evidence # that high weight edges are important for transmitting infections. v = rep(0,max(lcc_edges$weight)) for(w in 1:max(lcc_edges$weight)){ es = lcc_edges[lcc_edges$weight==w,1:2] v[w] = mean(lcc_verts$vic[as.numeric(es$from)] & lcc_verts$vic[as.numeric(es$to)]) } plot(v)