If you are going to do this make sure you have enough air coming in through your soffits. If you don't you will be drawing air from the vent right next to the fan. So how do you do that you ask? Well you go outside look at your soffit and count the little holes around your house measure the size of the holes add them all together and there you have it. Or you could find out who manufactured the soffit and they will list the Net Free Area ( NFA) in square inches. Multiply that by the linear feet of your soffit. Whatever that works out to be the number should be larger than the openings in your roof. In other words intake should be larger than the exhaust. Building codes have requirements for this. This video shows how different soffits restrict airflow.
https://www.youtube.com/watch?v=svfWcm126wE