4 use Bio
::Graphics
::Gel
;
6 use CXGN
::Genomic
::Clone
;
10 my $page = CXGN
::Page
->new;
12 my ($clone_id,$enzyme,$fingerprint_id) = $page->get_encoded_arguments(qw
/id enzyme fp_id/);
13 $fingerprint_id += 0; $clone_id += 0; #< enforce numericness
15 my $clone = CXGN
::Genomic
::Clone
->retrieve($clone_id)
16 or die "could not retrieve clone with id '$clone_id'";
18 my $is_frags = $clone->in_silico_restriction_fragment_sizes($enzyme);
20 my ($iv_frags) = grep {$_->[0] == $fingerprint_id && $_->[1] eq $enzyme } $clone->in_vitro_restriction_fragment_sizes($enzyme);
23 shift @
$iv_frags; shift @
$iv_frags; #shift off the fingerprint id and enzyme name
26 $is_frags || $iv_frags
27 or die "no restriction fragments available at all for this clone. user should not have been directed here.";
29 #warn "drawing fragment\n";
30 my $gel = Bio
::Graphics
::Gel
->new(
31 $iv_frags ?
('i.v.' => $iv_frags) : (),
32 $is_frags ?
('i.s.' => $is_frags) : (),
35 -bandcolor
=> [0xff,0xc6,0x00],
38 print "Content-Type: image/png\n\n";