Not only is your opponent's rating considered, but it's accuracy as well. The site uses the Glicko rating system. I took the liberty of doing a Search Forums for Glicko RD (rating deviation). I'm sure others can explain it better than I would. Oh, if you're handy with calculus and such, the exact formula can be found with a Google search.
http://www.chess.com/forum/search?keyword=Glicko+RD
also, is your opponent's rating considered?