Spatial connectivity and scaling for populations and communities