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

MathGroup Archive 2007

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

Search the Archive

Re: On partitioning lists by intervals

  • To: mathgroup at smc.vnet.net
  • Subject: [mg80446] Re: On partitioning lists by intervals
  • From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
  • Date: Wed, 22 Aug 2007 04:54:33 -0400 (EDT)
  • Organization: Uni Leipzig
  • References: <faea5n$ejf$1@smc.vnet.net>
  • Reply-to: kuska at informatik.uni-leipzig.de

Hi,

if you need a fixed length of the sub lists
lst=Table[Random[],{100}];

Partition[Sort[lst],10]

will help. But this is different from
"I need to get sublists of values that go from 0 to
 > 10, 10 to 20, etc"

BinCounts[lst,{0,1,0.1}]

Regards
   Jens

Mauricio Esteban Cuak wrote:
> Hello there.
> I'm just starting in mathematica and I realise this is a very basic
> question, but I tried to find an answer on the documentation center
> for a couple of hours and on the archive for mathgroup, but couldn't
> find it.
> I have a list of say 500 different random values. I need to divide it
> in n intervals of fixed length (for example, the lowest value is 0 and
> the maximum 100 so I need to get sublists of values that go from 0 to
> 10, 10 to 20, etc.)
> Thanks for your help!
> 
> cd
> 


  • Prev by Date: Re: On partitioning lists by intervals
  • Next by Date: Re: Any way to exclude branch-cut fills in this plot?
  • Previous by thread: Re: On partitioning lists by intervals
  • Next by thread: Re: On partitioning lists by intervals