Mathematica 9 is now available
Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1999
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1999

[Date Index] [Thread Index] [Author Index]

Search the Archive

"extending" BinCounts, need for speed

  • To: mathgroup at smc.vnet.net
  • Subject: [mg15871] "extending" BinCounts, need for speed
  • From: Olivier Pelletier <pelletie at lps.u-psud.fr>
  • Date: Wed, 17 Feb 1999 23:33:29 -0500
  • Organization: Universite Paris-Sud, France.
  • Sender: owner-wri-mathgroup at wolfram.com

Hi,

I have a huge (i.e. Length[list]>50000) list of points (a point being a
list {ai,bi})
I need to process it using a BinCounts-like function doing the
following:
if ai is in the i-th "bin" then I should add bi to the value of this
bin. (BinCounts  takes a list of numbers and adds unity to the bin
corresponding to the value of the number).
Using Do[bin[[ai]]+= bi, {i,Length[my_list]}] simply takes too much
time.
Any suggestion to improve the speed.
Thanks to everyone in advance

Olivier



  • Prev by Date: Re: graphing inequalities
  • Next by Date: Win 98 Printing Problems
  • Previous by thread: Re: Need Mathlink program Example
  • Next by thread: RE: "extending" BinCounts, need for speed