Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
1996
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 1996

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

Search the Archive

Re: a question on ContourPlot

  • To: mathgroup at smc.vnet.net
  • Subject: [mg4533] Re: [mg4441] a question on ContourPlot
  • From: Allan Hayes <hay at haystack.demon.co.uk>
  • Date: Wed, 7 Aug 1996 04:17:40 -0400
  • Sender: owner-wri-mathgroup at wolfram.com

"David E. Burmaster" <deb at alceon.com>
>Subject: [mg4441] a question on ContourPlot
writes
> I have made a complicated contour plot (on linear axes) that I
> would like to convert to semi-log axes....
> This does NOT work:
>	Show[ plot/.{a_, b_} -> {a, Log[b]}]
> That command converts the y-axis but does not transform the
> contours.....
> Could anyone pls suggest another approach?

David,

With
	cp = ContourPlot[x^2 -y^2, {x,.001,2}, {y,.001,2.72}]
cp contains only a matrix of heights from which the polygons and  
lines are constructed. It also has the option
	MeshRange -> {{0.001, 2.}, {0.001, 2.72}}.
The only effect of
	cp/{a_, b_} -> {a, Log[b]}
on cp is to change this option to
	MeshRange -> {{0.001, 2.}, {-6.90776, 1.00063}}
which, in the display, merely changes the y-axis ticks, as you found.

However if you generate the contour lines and polygons (used for  
shading) explicitely
	gcp = Graphics[cp]
Then
	lgcp = gcp/{a_?NumberQ, b_} -> {a, Log[b]}
will alter these elements as you want.
	Show[lgcp]
	
(You can see the internal form of cp... by using InputForm[cp] ...)
	
	
Allan Hayes
hay at haystack.demon.co.uk

	

==== [MESSAGE SEPARATOR] ====


  • Prev by Date: Re: ListPlot the output of Print
  • Next by Date: Re: How do I use Select[list,condition]?
  • Previous by thread: CDE and 'pinnable' windows...
  • Next by thread: Re: How do I use Select[list,condition]?