N.Y. Comp. Codes R. & Regs. tit. 18, § 360-3.4
(a) A person may not receive MA if he/she is:
(1) a resident of a public institution, as defined in section 360-1.4(1) of this Part unless the public institution is:
(i) an emergency shelter for the homeless, in which case MA is available:
(2) a patient in an institution for mental diseases unless he/she is: