Minor fixes in supplementary function