This is purely speculation, but I imagine it works in the same way as for cordless phone, i.e., the router scans the range of channels and picks one that has the least interference.
If you have a lot of problems with your wireless connection dropping, it may actually be better to select the channel yourself.