0
$\begingroup$

I have a H function which describe the location of the same temperature. I can draw the function with ContourPlot. But the real value of the temperature needed to be calculated separately. I need to plot the temperature on the Contour. How should I assign the value to the ContourPlot?

$\endgroup$
2
  • $\begingroup$ Uh :D ? ListContourPlot ? Otherwise add more details and try to clarify what exactly you need. $\endgroup$
    – Sektor
    Commented Dec 11, 2014 at 13:13
  • $\begingroup$ For custom labels see this nice post. $\endgroup$
    – SquareOne
    Commented Dec 14, 2014 at 17:59

1 Answer 1

1
$\begingroup$

ContourLabels displaying any quantity you wish can be created with an option of the sort, ContourLabels -> (Text[Framed[#3^2], {#1, #2}, Background -> White] &). In this case, it creates labels displaying the square of the contour value, but #3^2 can be replaced by any desired expression involving #3, the value of the plotted function. For instance, the ContourPlot produced by

ContourPlot[Sin[x - y], {x, 0, Pi}, {y, 0, Pi}, 
 ContourLabels -> (Text[Framed[#3^2], {#1, #2}, Background -> White] &)]

is

Sample plot

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.