Generalising the edge filter for undirected graphs