Length of in-hospital stay and its relationship to quality of care