Re: FilledPlot: Curves->Back option and Epilog not working?
- To: mathgroup at smc.vnet.net
- Subject: [mg56883] Re: [mg56861] FilledPlot: Curves->Back option and Epilog not working?
- From: "David Park" <djmp at earthlink.net>
- Date: Mon, 9 May 2005 01:46:03 -0400 (EDT)
- Sender: owner-wri-mathgroup at wolfram.com
That's one of the problems with DisplayTogether or Show. It only picks up an option (like Epilog) once from its first appearance. As for the Curves option, it only matters if you are plotting more than one fill in a FilledPlot statement. (You didn't actually give us working code so I don't know exactly what you were doing. Were you plotting more than one curve and fill with a single call of WavePlot?) With DrawGraphics you have none of these problems. Needs["DrawGraphics`DrawingMaster`"] waveDraw[ampl_, phase_, fillcolor_, mesg_, mesgloc_] := {FilledDraw[ampl*Sin[t + phase], {t, 0, 4*Pi}, Fills -> fillcolor], Text[StyleForm[mesg, FontColor -> ColorMix[fillcolor, Black][0.3]], mesgloc, {-1, 0}]} Draw2D[ {waveDraw[1, 20Degree, LightSteelBlue, "wave1", {0.2, 1.1}], waveDraw[0.6, 100Degree, Orchid, "wave2", {5, 0.7}]}, Frame -> True, Axes -> {True, False}, AxesFront -> True, PlotRange -> {-1.1, 1.3}, Background -> Linen, ImageSize -> 450] The only thing to worry about is that a subsequent filled wave will cover up a previous text label. It might be preferable to put the text labels in the Draw2D statement. David Park djmp at earthlink.net http://home.earthlink.net/~djmp/ From: AES [mailto:siegman at stanford.edu] To: mathgroup at smc.vnet.net I have a module that makes a filled plot. I use it to make two (or more) displaced filled plots, then Show these plots (code below). Everything works as expected, with two problems: * The Curves->Back option never works. * An additional line generated by an Epilog in the module only appears in the final test plot. I'm beginning to realize that when multiple plots each having an Epilog are combined using Show or DisplayTogether, only the *final* Epilog gets executed. Throwing in "Evaluates" at various stages in the process doesn't seem to get around this. If this is true, maybe the description of Epilog in the online Help should say this? (Especially since it seems an intuitively *non*obvious way for Epilog to behave -- shouldn't the stuff created by Epilog in a Plot command become part of the plot once the plot command has been executed?) I don't have a clue why Curves->Back doesn't work anywhere or any way I've tried it (including changing Front to Back in the online Help example). wavePlot[<args>] := Module[{}, <expressions>, FilledPlot[ <plot stuff> , Curves -> Back, Epilog -> {Line[ <line stuff> ]}, DisplayFunction -> Identity]]; <set all the args>; testPlot1 = wavePlot[ <args> ]; <reset all the args>; testPlot2 = wavePlot[ <args> ]; Show[testPlot1, testPlot2, DisplayFunction -> $DisplayFunction, PlotRange -> All];