It's not clear what you are asking - if she is in a nursing home there are often rules against spending the night away, doing so could cause her to be discharged.
When your in LTC you are a resident not a patient. The NH is now your home. Wife is not a prisoner. As long as you are doing what needs to be I see no problem taking her home.