I recently got assigned some projects that use PERL, and I have no experience with it so I'm flying solo here. So I apologize in advance for using the wrong terminology or not clarifying my question.
I have a section of code that groups records by diagnosis codes. Right now it groups anything that has a specific code number, but now I need to create a group of "everything else". Here's the current code. I need to change the Unspecified group to include everything not included in group A or group B, instead of having to list each one as I can have up to 100+ different diagnosis codes each time. The diagnosis codes are a text field, if that makes a difference, and some have numbers and letters.
@DiagGroupA = qw(2770 27700 27701 27702 27703 27707 27709); @DiagGroupB = qw(277); @UNSPECIFIED = qw(0704 07049); foreach $diagnosis (@DiagGroupA) { $DiagGroupA_list{$diagnosis} = 1; } foreach $diagnosis (@DiagGroupB) { $DiagGroupB_list{$diagnosis} = 1; } foreach $diagnosis (@UNSPECIFIED) { #$DiagUNSPECIFIED_list{$diagnosis} = 1;
In reply to Grouping Data by okieheart
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |