Re: Plotting question w/ customized X "buckets"
- To: mathgroup at smc.vnet.net
- Subject: [mg104031] Re: Plotting question w/ customized X "buckets"
- From: Jason Ledbetter <jasonbrent at gmail.com>
- Date: Fri, 16 Oct 2009 07:19:39 -0400 (EDT)
- References: <9e0fbc710910151615q25101b00l2d6ce4a4b5de77e9@mail.gmail.com>
I've been able to get a little closer to what I'm looking for: {x, y} = Transpose[data]; BarChart[y, ChartLabels -> Placed[x, Below, Rotate[#, 70 Degree] &], AspectRatio -> 0.25, ImageSize -> 1000, LabelingFunction -> Above] However I've yet to test this with multiple "y" data sets.... I'm really looking for points across the Y axis, all color coded the same in a ListLine form by buckets across the X axis like the above plot generates, however. -jbl On Thu, Oct 15, 2009 at 7:15 PM, Jason Ledbetter <jasonbrent at gmail.com>wrote: > Folk (yes, me again..), > I've got a dataset that I'm trying to Plot with the X axis defined as > histogram-ish buckets and the Y axis as the integer values but I'm having > problems getting the X axis as I'd like. > > data = {{"0 - <1ms", 113}, {"1 - <2ms", 19}, {"2 - <4ms", 176}, {"4 - > <6ms", > 243}, {"6 - <8ms", 260}, {"8 - <10ms", 167}, {"10 - <12ms", > 65}, {"12 - <16ms", 41}, {"16 - <20ms", 13}, {"20 - <30ms", > 7}, {"30 - <40ms", 0}, {"40 - <50ms", 1}, {"50 - <60ms", > 0}, {"60 - <70ms", 0}, {"70 - <80ms", 0}, {"80 - <90ms", > 0}, {"90 - <100ms", 1}, {"100 - <120ms", 1}, {"120 - <140ms", > 0}, {"140 - <160ms", 0}, {"160 - <180ms", 1}, {"180 - <200ms", > 0}, {"200 - <400ms", 2}, {"400 - <600ms", 0}, {"600 - <800ms", > 0}, {"800 - <1000ms", 0}, {"1000 - <1500ms", 0}, {"1500 - <2000ms", > 0}, {"2000 - <2500ms", 0}, {"2500 - <3000ms", 0}, {"3000 - <3500ms", > 0}, {"3500 - <4000ms", 0}, {"4000 - <8000ms", 0}, {"8000 - <12000ms", > 0}, {"12000 - <16000ms", 0}, {">16000ms", 0}}; > > > I'm ultimately looking to graph multiple of these datasets on the same plot > with a unique color for the y in each inner {x,y} pair, the x should define > which "bucket" the work fits into and the y value how many times this > workload fit into the bucket. > > > Can I beg for some examples of how to do this? I can readily pull out the x > or y values using Transpose and graph those but they always end up on the X > axis instead of the Y.. Histogram[] gets me closer but I believe it is > trying to do more automatically than is necessary since the dataset already > defines the bins and values. > > > Is this a situation where the plot needs to be built up by hand using > Graphics[]? > > > Thanks in advance for any assistance that can be provided. > > > -jbl > > > > >