Predictors of length of stay in an acute psychiatric inpatient facility in a general hospital: a prospective study