Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2009

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

Search the Archive

RE: Keeping plot annotations after regenerating a plot

  • To: mathgroup at smc.vnet.net
  • Subject: [mg95239] RE: [mg95217] Keeping plot annotations after regenerating a plot
  • From: "David Park" <djmpark at comcast.net>
  • Date: Mon, 12 Jan 2009 06:23:31 -0500 (EST)
  • References: <2975445.1231675830353.JavaMail.root@m02>

Sjoerd,

As appealing as the drawing tools may seem, I must disagree that they are a
solution to producing professional custom graphics and displays. My reason
for saying this is that they do not provide a precise written description of
the graphics, which can then be modified. The drawing tools might be
suitable for quick sketches but I don't believe they are suitable for
graphics that undergo a process of development and modification.

What happened is that you found the problem with using drawing tools, and
then found a fix and way around it. But how many times might a custom plot
need to be modified in the process of development? How many times will it be
necessary to go through the fix? Does this work with dynamics, or within a
Manipulate statement? (I don't actually know.)

It is much better to have a SINGLE explicit specification statement for a
generated graphic, or combined dynamic graphic and page display. Making a
good custom graphic generally takes a fair amount of work because there is
much detail to specify.

The Presentations package makes it much easier to construct custom graphics,
and now also dynamic page displays combining graphics with other
expressions. One can just specify one thing after another, with primitives
from any of the standard plot types.

I just finished a dynamic presentation that contains movable line segments,
step by step construction of a geometric diagram with checkboxes, several
sliders built intoa textual display, an action button, a graduated ruler
that can be moved. The calculations for the last operation are time
consuming in a dynamic display and are triggered only when the ruler is
moved. The entire presentation took several days to develop and ended up
much longer and different than the initial design. Trying to do this with
drawing tools or within a Manipulate statement would have been extremely
difficult, and frustrating - if it was even possible.

Developing professional displays takes a lot of work because of all the
essential detail. Working without explicit written specifications, or trying
to twist something like the baroque Manipulate statement to specific needs
is simply impossible.   


David Park
djmpark at comcast.net
http://home.comcast.net/~djmpark/  



From: Sjoerd C. de Vries [mailto:sjoerd.c.devries at gmail.com] 


I really like the possibility to manually add graphics and text to a
plot using the Mathematica 6/7 drawing tools palette. It's often much
quicker
than having to program them. However, more often than not, just after
I finish making those annotations I discover that I used the wrong
parameter value for the plotted model or want larger axes label fonts
or so.

Problem is, when I regenerate the plot I'll erase my own annotations
and I have to redo them. I found some sort of solution that I'd like
to share. Perhaps you folks know of a better solution?

* Assign your first plot with annotations to a variable, say y.
* Re-generate the first plot (without annotations) and with essential
font change; call it x
* Execute:

x[[1]] = {x[[1]], y[[1, 2 ;; -1]]};

and x now has your old annotations.

Seems to work for most 2D plots. I tried Plot, ListPlot, DensityPlot
and ContourPlot and a few of their options. Not sure whether it is
really robust.

Cheers -- Sjoerd




  • Prev by Date: Re: Need to calculate daily risk free rate from Fed data
  • Next by Date: Re: Re: Plot in Background of Manipulate
  • Previous by thread: Re: printing symbols at as a table
  • Next by thread: Re: Graphics in PlotMarkers buggy in Mathematica 7