Re: Re: Re: Non numerical x-axis in
- To: mathgroup at smc.vnet.net
- Subject: [mg79053] Re: [mg79026] Re: [mg78997] Re: [mg78986] Non numerical x-axis in
- From: Murray Eisenberg <murray at math.umass.edu>
- Date: Tue, 17 Jul 2007 03:20:56 -0400 (EDT)
- Organization: Mathematics & Statistics, Univ. of Mass./Amherst
- References: <29106105.1184503723560.JavaMail.root@m35> <200707160615.CAA24650@smc.vnet.net>
- Reply-to: murray at math.umass.edu
Because the option is now merely Joined, not PlotJoined! DrMajorBob wrote: > That works fine, but I'm wondering why "PlotJoined" is color-coded red -- > indicating it's not a recognized option? (version 6.0.1) > > Bobby > > On Sun, 15 Jul 2007 00:08:08 -0500, Bob Hanlon <hanlonr at cox.net> wrote: > >> The Sort included below is to cover the case when the data is not >> pre-sorted by labels >> >> dat1 = {{"A1", 2}, {"A4", 1}, {"A2", 3}}; >> dat2 = {{"A1", 2.2}, {"A3", 0.5}, {"A2", 2.9}, {"A4", 1.1}}; >> >> xcoord = Union[Join @@ (#[[All, 1]] & /@ {dat1, dat2})]; >> >> dat = Sort /@ ({dat1, dat2} /. >> {x_, y_?NumericQ} :> >> {Position[xcoord, x][[1, 1]], y}); >> >> ListPlot[dat, >> PlotJoined -> True, >> Frame -> True, >> FrameTicks -> {Thread[{Range[Length[xcoord]], xcoord}], >> Automatic, None, None}, >> Epilog -> {AbsolutePointSize[4], >> Thread[{{Blue, Red}, Map[Point, dat, {2}]}]}] >> >> >> Bob Hanlon >> >> ---- Maarten van der Burgt <maarten.vanderburgt at icos.be> wrote: >>> Dear all, >>> >>> I have two sets of data: >>> >>> dat1 = {{"A1",2},{"A2",3},{"A4",1}} >>> dat2 = {{"A1",2.2},{"A2",2.9},{"A3",0.5},{"A4",1.1}} >>> >>> Is there a simple way I can plot these with the {"A1", "A2", "A3", >>> "A4"} as >>> equidistant tick marks/labels along the horizontal axis and a standard >>> numerical vertical axis? >>> Note the missing "A3" in dat1. >>> >>> I could not find anything in the options of ListPlot, or in the new >>> (6.0) >>> DateListPlot. >>> >>> Thanks for your help, >>> >>> Maarten van der Burgt >>> Leuven, Belgium >>> >>> >> >> > > > -- Murray Eisenberg murray at math.umass.edu Mathematics & Statistics Dept. Lederle Graduate Research Tower phone 413 549-1020 (H) University of Massachusetts 413 545-2859 (W) 710 North Pleasant Street fax 413 545-1801 Amherst, MA 01003-9305
- References:
- Re: Re: Non numerical x-axis in (Date)ListPlot?
- From: DrMajorBob <drmajorbob@bigfoot.com>
- Re: Re: Non numerical x-axis in (Date)ListPlot?