0
$\begingroup$

I have plotted the following:

p1 = Plot[Sin[x], {x, 0, 3 \[Pi]}, PlotStyle -> Red, 
   PlotLabels -> Placed["Cat1", Above]];
p2 = Plot[Cos[x], {x, 0, 6 \[Pi]}, PlotStyle -> Blue, 
   PlotLabels -> Placed["Cat2", Above]];
Show[p1, p2, PlotRange -> All]

which gives:

enter image description here

Now I wonder how one can change the labels into pictures of two cats? link to cat1 and cat2. Surly this might be funny but the point of my question is to know how to label plots using images?

$\endgroup$

closed as off-topic by Alexey Popkov, rhermans, m_goldberg, MarcoB, Öskå Jul 28 at 11:34

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "This question arises due to a simple mistake such as a trivial syntax error, incorrect capitalization, spelling mistake, or other typographical error and is unlikely to help any future visitors, or else it is easily found in the documentation." – Alexey Popkov, rhermans, m_goldberg, MarcoB, Öskå
If this question can be reworded to fit the rules in the help center, please edit the question.

3
$\begingroup$

Try this

p1 = Plot[Sin[x], {x, 0, 3 \[Pi]}, PlotStyle -> Red, 
   PlotLabels -> Placed["Cat1", Above]];
p2 = Plot[Cos[x], {x, 0, 6 \[Pi]}, PlotStyle -> Blue, 
   PlotLabels -> Placed[Import["ExampleData/spikey.tiff"], Above]];
Show[p1, p2, PlotRange -> All]

which produces

enter image description here

Now replace the spikey with your cat images.

I'm prompted to wonder aloud that you didn't find this for yourself.

$\endgroup$

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