Clearly not. Let the measure space be the uniform measure on {$1,2,3,4$}. $A$ allows you to discern whether the number is greater or less than $2.5$ or not. $B$ allows you to discern whether the number is 0 or 1 mod $2$. Let $f$ be $x^2-5x+6$, then $E^Af=1$, $E^B f=1$, $E^{A,B}f=f$. One can't write $f$ as any polynomial or olgebraic expression in $1$ and $1$.
Edit: If you want $A \cap B$ instead of $A \cup B$ you can use $\lim \dots E^A E^B E^A E^B E^A E^B$, if the limit exists, since that is the projection onto the subspace fixed by both $E_A$ and $E_B$, which is the subspace of functions defined over both $A$ and $B$, which is the subspace you want to project onto.

