Fix TIN analysis functions