[Bio] / FigKernelScripts / ec_compare_sib.pl Repository:
ViewVC logotype

View of /FigKernelScripts/ec_compare_sib.pl

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (download) (as text) (annotate)
Sun Sep 13 19:46:12 2015 UTC (4 years, 2 months ago) by redwards
Branch: MAIN
CVS Tags: HEAD
module and scripts to compare EC numbers to what we have in the SEED

#__perl__
#

=pod

Download the latest ec file (enzyme.dat) from Expasy and then parse it to check what we have

Written by Rob Edwards 9/13/2015

=cut

use strict;
use FIG;
my $fig = new FIG;
use ParseSIBEnzyme;

#use Data::Dumper;

my $garyF = "/homes/golsen/public_html/core_seed.func.ss.dlit.counts.tab";

my $parser = ParseSIBEnzyme->new();
$parser->get_datafile();
my $data = $parser->parse();

my %del = map {($_=>1)} @{$data->{'deleted'}};
my %tra = map {($_=>1)} @{$data->{'transferred'}};

open(IN, $garyF) || die "$!: $garyF";
while (<IN>) {
	chomp;
	my @a=split /\t/;
	my $fn = $a[6];
	my $fnc = $fn;
	while ($fnc =~ s/EC\s+(\d+\.\d+\.\d+\.\d+)//) {
		my $id = $1;
		if ($tra{$id}) {print join("\t", $fn, $id, $data->{$id}->{"DE"}), "\n"}
		if ($del{$id}) {print join("\t", $fn, $id, $data->{$id}->{"DE"}), "\n"}
		if (!defined $data->{$id}) {print STDERR "NOT VALID: $id\n"}
	}
}


MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3