As I understand it, the paths D <- Ed -> St -> P -> Su and D <- A -> P -> Su are both closed because the contain the collider P. If I condition on P, both these paths will be open.
But that doesn't seem to be the case according to dagitty:
library(dagitty)
d = dagitty('dag {
A -> D
A -> P
D -> Em
D -> Su
Ed -> D
Ed -> St
Em -> Su
P -> Su
Se -> D
Se -> Su
St -> P
St -> Su
}')
p = paths(d, from = 'D', to = 'Su')
p$path[p$open]
[1] "D -> Em -> Su" "D -> Su" "D <- A -> P -> Su"
[4] "D <- Ed -> St -> P -> Su" "D <- Ed -> St -> Su" "D <- Se -> Su"
Also if I condition on P, it doesn't open the two paths mentioned at the start, but does open the path D <- A -> P <- St -> Su.
Have I misunderstood the backdoor criterion? Does it have something to do with P being immediately next to the outcome Su?