I can feel your pain. Have a blood test, and see just how much T is in your system, as well as progesterone. If you look at these 2, and they are high or medium for a female, that generally will contribute to you having erections. And sometimes, your body will induce an erection if you need to go to the toilet when you are asleep.