in reply to Re^3: Position Weight Matrix of Set of Strings
in thread Position Weight Matrix of Set of Strings
But why it returns this answer:my @inst = ( 'CAGGTG', 'CAGGTG' ); my $res1 = get_pwm(@inst);
Instead of the correct$VAR1 = { 'A' => [ 0, '1' ], 'T' => [ 0, 0, 0, 0, '1' ], 'C' => [ '1' ], 'G' => [ 0, 0, '1', '1', 0, '1' ] };
It seems that the code didn't supply 0 when the bases is not present in a particular column as it should after it found 1.$VAR1 = { 'A' => [ '0', '1', '0', '0', '0', '0' ], 'T' => [ '0', '0', '0', '0', '1', '0' ], 'C' => [ '1', '0', '0', '0', '0', '0' ], 'G' => [ '0', '0', '1', '1', '0', '1' ] };
Please advice.@$_ = map { $_ ? $_ / $n : 0 } @$_ for values %pwm;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: Position Weight Matrix of Set of Strings
by BrowserUk (Patriarch) on Sep 07, 2006 at 03:55 UTC | |
by monkfan (Curate) on Sep 19, 2006 at 01:05 UTC | |
by BrowserUk (Patriarch) on Sep 19, 2006 at 01:23 UTC |