People on drugs or with severe mental health issues are probably unable to be in the population admitted to a shelter and is in the street. Certainly, since the average shelter stay is over a year and 4 months, any concerns about them being bad tenants would assume they behave significantly differently in an apartment than in a shelter that will kick them out.
Yes it's a cost/lack of money question. If only economics told us what we'd expect to see happen if the supply of a resource priced out of peoples budget (long term housing) was increased.