in reply to Re^2: How to match duplicate lines in a text file and extract only one of those lines to a new file
in thread How to match duplicate lines in a text file and extract only one of those lines to a new file

In your original sample data, every line began with two integers and then a text string. Now you seem to be running it on lines that begin with a single integer and a text string, so his code is picking up the first allele as part of the duplicated section.

Aaron B.
My Woefully Neglected Blog, where I occasionally mention Perl.

  • Comment on Re^3: How to match duplicate lines in a text file and extract only one of those lines to a new file

Replies are listed 'Best First'.
Re^4: How to match duplicate lines in a text file and extract only one of those lines to a new file
by danica (Initiate) on Apr 05, 2012 at 09:26 UTC
    Oh yes of course! Thank you for pointing out such an obvious mistake!