States benefit, or not, from federal spending