Re: Tooltips in ContourPlot
- To: mathgroup at smc.vnet.net
- Subject: [mg81761] Re: [mg81726] Tooltips in ContourPlot
- From: DrMajorBob <drmajorbob at bigfoot.com>
- Date: Wed, 3 Oct 2007 02:26:17 -0400 (EDT)
- References: <20420439.1191327783997.JavaMail.root@m35>
- Reply-to: drmajorbob at bigfoot.com
Like this:
ContourPlot[
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]], {x, -6, 6}, {y, -6, 6}] /.
Tooltip[x_, s_] :> Tooltip[x, "hello"]
There are eight Tooltip instances in the original plot, one for each line:
Cases[ContourPlot[
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]], {x, -6, 6}, {y, -6, 6}],
Tooltip[x_, s_] :> {Head@x, s}, Infinity]
{{Line, Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]]}, {Line,
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]]}, {Line,
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]]}, {Line,
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]]}, {Line,
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]]}, {Line,
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]]}, {Line,
Re[Cosh[x + \[ImaginaryI] y]] ==
Re[Sin[x + \[ImaginaryI] y]]}, {Line,
Re[Cosh[x + \[ImaginaryI] y]] == Re[Sin[x + \[ImaginaryI] y]]}}
Bobby
On Tue, 02 Oct 2007 04:40:17 -0500, David Park <djmpark at comcast.net> wrote:
> Is it possible to control what is displayed in Tooltips in contour plots?
> For example, in the following plot:
>
> ContourPlot[
> Re[Cosh[x + \[ImaginaryI] y]] ==
> Re[Sin[x + \[ImaginaryI] y]], {x, -6, 6}, {y, -6, 6}]
>
> would it be possible to change the Tooltip to Re[Cosh[z]] == Re[Sin[z]]
> or
> to some descriptive text?
>
--
DrMajorBob at bigfoot.com