Skip to content

Instantly share code, notes, and snippets.

@andrawaag
Last active December 17, 2015 23:29
Show Gist options
  • Save andrawaag/5689843 to your computer and use it in GitHub Desktop.
Save andrawaag/5689843 to your computer and use it in GitHub Desktop.
open DISEASEGENEFILE, "N:/FHML_BIGCAT/Bioinformatics/Programming/mart.txt";
open EXPRESSIONFILE, "N:/FHML_BIGCAT/Bioinformatics/Programming/GeneExpression.txt";;
%disease = {};
while($line = <DISEASEGENEFILE>){
@fields = split(/\t/, $line);
if ($fields[2] ne ''){
$disease{$fields[0]} = $fields[2];
}
}
while($line = <EXPRESSIONFILE>){
@fields2 = split(/\t/, $line);
if ($disease{$fields2[0]} ne ""){
print $fields2[0]."->".$disease{$fields2[0]};
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment