Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^10: Random sampling a variable length file.

by BrowserUk (Patriarch)
on Dec 30, 2009 at 11:51 UTC ( [id://814919]=note: print w/replies, xml ) Need Help??


in reply to Re^9: Random sampling a variable length file.
in thread Random sampling a variable record-length file.

Because there might be (for example) a time-related correlation. If the file in question were a log file running midnight to midnight, it's possible that there might be less activity at either end of the day than in the middle.

Or (for example), the file might have been previously ordered in some way that means the longer records are at the front and shorter at the end.

Whilst it is possible that a random selection picked across the length of any given file might pick all the longest (or shortest), it is far,far less likely, than likely. That's why you pick a random sample.

It is the whole basis of normal distributions, the 68-95-99.7 rule, and the associated statistics.


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
  • Comment on Re^10: Random sampling a variable length file.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2024-06-23 14:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?
    erzuuli‥ 🛈The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.