Stress neurotransmitters in the brain are much less active during the REM stage of sleep even during dreams of traumatic experiences.
This made some scientists to think that one purpose of dreaming is to take the edge off painful experiences to allow for psychological healing.
People with certain mood disorders and PTSD often have difficulty sleeping, leading some scientists to believe that lack of dreaming may be a contributing factor to their illness.