diag_expand function

Creates a square matrix suitable for spatial statistics models.