@rybern please also review this entire inner function. It is difficult to see where I made changes because this file was indented with tabs and I had to also fix that as part of this pull request. The change I made here was to fix a bug where sequences from filtered out samples were being processed (resulting in an ```IndexError```). I also fixed the abundance calculation code- it was previously using the number of sequences as the abundance, but this could have been incorrect if samples are filtered out.