Beefy Boxes and Bandwidth Generously Provided by pair Networks httptech
Just another Perl shrine
 
PerlMonks  

Re: how to make this code more efficient? Need to Compute the Min and Max of a Temperature using an equation

by almut (Canon)
on Apr 19, 2010 at 19:19 UTC ( #835575=note: print w/ replies, xml ) Need Help??


in reply to how to make this code more efficient? Need to Compute the Min and Max of a Temperature using an equation

while (my $uniqueseq = $stream->next_seq()) { push @oligomers, $uniqueseq->seq; }

Instead of expanding all possible combinations into an array that you then iterate over, why not directly call tm_Base_Stacking(...) (or tm_NNH() for that matter(?)) in that loop?

That should at least get rid of the memory problem (unless the Bio::Tools::IUPAC iterator internally pre-expands the set itself), although the runtime problem would likely still persist...


Comment on Re: how to make this code more efficient? Need to Compute the Min and Max of a Temperature using an equation
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://835575]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (6)
As of 2014-04-20 08:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (485 votes), past polls