Hi Sara!
I had to live in Rio de Janeiro about 6 months. Im highly recommend and I wanna say it is very good place for to live and enjoy your life 
So what about dangerous.. My advise is Don't Think About, really =)
Just avoid to live on favela. Generally people are good there, but exists some kind of people who could rob you.
I lived in Copacabana and Barra. Both places are good and safe.
Copa is more touristic place, easy to reach beach, bars, shopping, met another expats or nomades etc.
Barra is quite far from all touristic places, but many buses there, so you can go everywhere in Rio. Also good infrastructure and very nice beaches.
If you are going live there, try to rent apartments close to the beach.
Enjoy my lovely Rio!