Testosterone in men is highest first thing in the morning, assuming you have normal circadian rhythms and sleep at relatively normal times. That explains the erection and it's also possible you're having the beginning of a wet dream. If you had prostatitis, which isn't a disease, just a description of an inflamed prostate but not why it's inflamed, and you're way too young for that to be likely, it would have some symptoms you would notice. This is isn't one of them. It would be some pain or problem urinating or the like.