The purpose of therapy is to work through your inner turmoil in order to understand the crazy crap going on in your head. The assistance of a guide (therapist) can ease this process, but it is not needed if you can simply sit down and force yourself to articulate the aforementioned crazy crap.
Emotions that refuse to be identified combined with real life problems can result in a less than happy lifestyle. However, simply allowing your feelings to channel through the filter of your ability to form words can show you things about yourself that would have gone previously ignored or justified. Not only can you have moments of enlightenment while writing introspectively, but you can also use that amazing gift of hindsight to look at what a nut you sound like when you're pissed.
Writing letters to people and never sending them (that last part is important, here) can also be theraputic. Working out for yourself your true feelings for somebody or just venting and detailing all the various shades of angry they make you sometimes can be healthy. This can also allow you to work through some difficult things that may need to be discussed beforehand.
Not only negative or elusive emotions can be expressed through the private medium of writing, but also the naughty ones. Sexual fantasies are given life when written out in exquisite detail. Combining creative ability with the drive of the libido can make for some very powerful smut, indeed. Discovering one's own preferences or tastes in the safe environment of writing a story can be a fun way to explore the idea of new things without any of the real life danger or ridicule (you freak).
Writing is the focus here, but the real key is ordered introspection and thoughtful retrospect. Keeping a journal or just having some documents on your computer can easily become a method to think about life's problems in a critical and helpful way. Of course, keeping these things hidden and private is crucial, which is why things like blogs make terrible mediums for actual writing of this kind. It's crucial that you have something which isn't online anywhere (and is also hidden). This does not exclude the idea of eventually showing others what you have written, especially if you've written smut, but you need to feel safe enough to say whatever comes to mind, have no fears and don't censor yourself at all. Remember, you're with the only audience that truly understands you.