By shifting cargo/ballast/personnel about the vessel, the stability of the vessel can be altered advantageously or adversely. By shifting weight from higher up in a ship to a lower position, one would be lowering the centre of gravity and therefore increasing the stability. However, if the centre of gravity is lowered too much this can make the ship very stiff and uncomfortable.
By shifting it in the reverse direction, the vessel will become less stable and again too much might result in an unstable equilibrium and place the ship in danger of capsizing. Moving weight off-centre will have the effect of shifting the centre of gravity off centre and this would cause the ship to list.
Shifting weight fore and aft will also alter the trim of the vessel and its handling characteristics. Obviously, the shifting of weight can be used to counter adverse conditions of stability as well.