Bug testing code streamline, up to abundance calculation