Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Mean calculation problem

by bobf (Monsignor)
on Jan 13, 2010 at 06:52 UTC ( [id://817118]=note: print w/replies, xml ) Need Help??


in reply to Mean calculation problem

I got stuck in the regex

I would suggest starting with CPAN rather than writing your own parser. Bio::Structure::IO, Chemistry::File::PDB, Chemistry::Mol all look relevant, and there are likely several more. If you use an existing module to do the low-level work, you can focus on the real reason you are writing the code (i.e., it isn't because you want to parse a PDB file, it is because you want to do something with the contents of the file).

If you insist on rolling your own parser, look at unpack. It is great for fixed-width data, and will likely be much faster and less buggy than any regex you assemble.

HTH

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (7)
As of 2024-04-18 06:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found