Absolutely. It has been that way with all my dogs all my life. When I was 21 I had bleeding ulcers and was throwing up blood. I only had one dog at the time and she was so scared she hid in my walk in closet and one time she layed her head on me.
After that i moved backk to my parents house b/c they didn't want me to be by myself. Before that I had lived n the same mobile home park my oldest brother he did. He called us and said my dog was back in the mobile home park b/c she missed me so we brought her hack home.
I have heard they have dogs in nursing homes and trained personnel train dogs to keep prisoners company.