Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Faster Statistics for Discrete Data

by rinceWind (Monsignor)
on Feb 22, 2002 at 10:24 UTC ( #146919=note: print w/replies, xml ) Need Help??


in reply to Faster Statistics for Discrete Data

Couldn't you just tie the array and use the original package? Something like Tie::MmapArray could be used to map your array to a disk file.
  • Comment on Re: Faster Statistics for Discrete Data

Replies are listed 'Best First'.
(RhetTbull) Re: Re: Faster Statistics for Discrete Data
by RhetTbull (Curate) on Feb 23, 2002 at 18:12 UTC
    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.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://146919]
help
Chatterbox?
[jdporter]: one prog I have has a UI which allows to input a bit mask
[jdporter]: currently it expects the bitmask to be in the form of a hex number, e.g. 0x0101
[jdporter]: but I'd like to let the user specify it as individual bits, i.e. 0b0000000100000001
[jdporter]: there is no bit/binary equivalent of hex, right?

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (6)
As of 2018-02-20 16:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    When it is dark outside I am happiest to see ...














    Results (272 votes). Check out past polls.

    Notices?