Re: Re: Need help with HISTOGRAM plotting
- To: mathgroup at smc.vnet.net
- Subject: [mg51440] Re: [mg51410] Re: [mg51388] Need help with HISTOGRAM plotting
- From: DrBob <drbob at bigfoot.com>
- Date: Sun, 17 Oct 2004 03:06:01 -0400 (EDT)
- References: <200410150648.CAA05350@smc.vnet.net> <200410160820.EAA23710@smc.vnet.net>
- Reply-to: drbob at bigfoot.com
- Sender: owner-wri-mathgroup at wolfram.com
Or this: Needs["Graphics`Graphics`"] hst = {97, 90, 91, 98, 93, 100, 90, 98, 91, 93, 98, 93, 97, 93, 80, 95, 93, 99, 96, 80, 98, 85, 94, 98, 96, 88, 93, 92, 88, 97, 90, 90}; Histogram[hst, HistogramCategories -> Range[Min@hst, 1 + Max@hst]] Bobby On Sat, 16 Oct 2004 04:20:46 -0400 (EDT), János <janos.lobb at yale.edu> wrote: > > On Oct 15, 2004, at 2:48 AM, Peet wrote: > >> I've only been playing around with the trial version of Mathematica >> for a few hours but I can't figure out how the heck to plot a >> histogram. I have a list of data (below) that I want to plot. The >> range is 80 to 100 and I want 5 bins, across 4 points each. I feel >> that this is a pretty straightforward thing to do, but I can't even >> plot a single histogram, even when I reproduce the samples that they >> give in the math book word for word. The data is below, any help would >> be greatly appreciated. >> >> 97,90,91,98,93,100,90,98,91,93,98,93,97,93,80,95,93,99,96,80,98,85,94,9 >> 8,96,88,93,92,88,97,90,90 >> >> > > Needs["Graphics`Graphics`"] > hst = {97, > 90, 91, 98, 93, 100, 90, 98, 91, 93, 98, 93, 97, 93, 80, 95, 93, 99, > 96, 80, 98, 85, 94, 98, 96, 88, 93, 92, 88, 97, 90, 90}; > > BarChart[Map[{Length[#], #[[1]]} &, Split[Sort[hst]]]] > > It is a width=1 histogram. > > János > ---------------------------------------------- > Trying to argue with a politician is like lifting up the head of a > corpse. > (S. Lem: His Master Voice) > > > > -- DrBob at bigfoot.com www.eclecticdreams.net
- References:
- Need help with HISTOGRAM plotting
- From: mediocretes@gmail.com (Peet)
- Re: Need help with HISTOGRAM plotting
- From: János <janos.lobb@yale.edu>
- Need help with HISTOGRAM plotting