Samurai were trained to follow their lords even if it meant leaving their family., some times when samurai a loses a war and survives. Their is a ritual called sippaku where samurai commit suicide to die a honorable death.
These warriors need a trainer right, we need the shogun. The shogun is the supreme commander of Japan's army and the country itself.
Another high ranking person in Japan is the daimyo. The Daimyo is a powerful Japanese land owner with their own private army's guarding their lands.