something planned or unplanned?
Hospitals are not allowed to keep you against your will unless they petition to have you committed, which usually only happens in cases of extreme injury/sickness or when a patient is not of sound mind.
You're free to leave AMA (Against Medical Advice). This is how it works in the States, at least. I'd hedge a bet that Canada is no less draconian than the US in that aspect
I'm glad you're where you're want to be for now. I hope everything works out.
are you still waiting for this? if you had waited in-hospital would you still be there waiting?