A framework for estimating the determinants of spatial and temporal variation in vital rates and inferring the occurrence of unobserved extreme events