The role of population and wealth in international capital flows