Use sprintf to set the number of significant digits you want:
# rounds to 0.01 (assumes positive number):
my $cleanFloat = sprintf "%.2f", $dirtyFloat + 0.004;
# truncates to 0.01:
my $cleanFloat = sprintf "%.2f", $dirtyFloat;
update: it appears that sprintf internally rounds, which makes my "truncates" example not do so. However, the "rounds" example may be better, as it gets around sprintf's buggy rounding.
update2: but since sprintf does buggy rounding for 0.5, it would be better to add 0.004; changed this.