Your idea is great, but the problem is that
igraph::clusters(g)$csize < 10
returns only a logical cluster vector containing less than 10 members. Meanwhile, you need to know which vertices belong to these clusters.
Therefore, we can act as follows.
set.seed(1)
g1 <- erdos.renyi.game(100, 1 / 70)
cls <- clusters(g1)
cls$csize
g2 <- delete_vertices(g1, V(g1)[cls$membership %in% which(cls$csize <= 10)])
plot(g2)

source
share