6
$\begingroup$

I would like to export a listplot as a PDF document without loosing the tooltip information on the single points. It kind of works with hyperlinks. Nevertheless this workaround is pretty limited and does e.g. not offer graphics as tooltips.

Looking forward any ideas!

Thanks and best regards Patrick

data = {{1, 2}, {2, 3}, {3, 5}, {4, 7}};
hlinks = Text[
StringForm["``", 
 Hyperlink[" ", "http://" <> ToString[#[[2]]]]], #] & /@ data;
chart = Show[ListPlot[data, AxesOrigin -> {0, 0}], Graphics[hlinks]];
Export["C:\\Users\\myname\\Desktop\\scatterplot.pdf", chart]
$\endgroup$
2
$\begingroup$

You can export it to html format then use tool to transfer it.

Export["scatterplot.html", chart]

Press this point then goto the link below: enter image description here

enter image description here

Finally you can refer Print HTML to PDF while retaining hyperlinks and How do I preserve hyperlinks when converting webpages to pdf? to transfer it.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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