I'm just working through this example (Example 2), using moments and resolving forces to find the centre of gravity of three particles. I understand resolving the forces and finding $\bar{x}$, but I don't understand what's going on with finding $\bar{y}$ - since $\bar{y}$ is never perpendicular to the force (the weight), I don't see how it can be used for finding moments?
Unless is down (the direction weight goes) actually into the page and not in the negative $y$ direction? I suppose it shouldn't matter... This is very confusing!
Any help gratefully received, thank you!

Given a mass system $m_k,\ k= 1,\cdots, n$ and an axis $\eta$, the mass system first moment regarding $\eta$ is equal to the resulting mass at the so called center of mass, times the distance regarding $\eta$. Choosing the $y$ axis we have
$$ \sum_{k=1}^n m_k y_k = \left(\sum_{k=1}^n m_k\right)y_g $$
then
$$ y_g = \frac{\sum_{k=1}^n m_k y_k}{\sum_{k=1}^n m_k} $$