I remember being in the hospital once and having a patient ask me if it was legal for him to leave the hospital if his doctor had refused to release him, or if he could be arrested if he left. Of course this was an absurd question, since keeping someone in a hospital who does not want to be there is false arrest, and a doctor has no arrest powers!