Actually, tying to a file has some drawbacks. Foremost of which is that you have to have a file to tie to. I often pipe in data from another program or read in the data from a database. A tied file approach would require the overhead of writing to disk and reading back. Also, some statistics (such as median) require the data to be in sorted order -- that means you'd have to sort the file in memory or sort and write to disk again which defeats the purpose. The approach I used gets around all of those limitations -- you don't need an intermediate file and you don't have to sort the original data points.
Are you posting in the right place? Check out Where do I post X? to know for sure.
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
Want more info? How to link or
or How to display code and escape characters
are good places to start.