Sex ratio and doses given to older age groups affect gender gap in vaccination