I actually experimented quite a bit with this years ago after having some strange experiences that I couldn't explain.
Just as you described it in your post, it does seem to occur more often when you are in between being awake and asleep. Although, I have had experiences that have occurred while I was asleep that pulled me out of the dream state, most seemed to happen just as I was about to fall asleep.
Also, I found that once I was able to do it, there was a certain sensation that is very distinct that your body seems to remember making subsequent experiences easier to obtain. There were times when I had to fight not leaving my body. Not sure if you experienced this as well?
Would love to hear more about your experiences and what has taken place or anyone else on this site who has had experiences with this too.