简体   繁体   中英

How do I label points in datashader?

So I know this sounds like a dumb question but I want to plot around a million points and then label each one of them in a huge 12000/12000 px canvas and then print it out for a project - how do I go about doing this?

Datashader focuses on accurately rendering datasets that have many different datapoints falling into each pixel, aggregating them to give the user an indication of the true distribution even when the individual points are not visible. If you are labeling individual points, by definition there must not be very many points per pixel, or else the labels will overlap and be unreadable. So in that case I don't think Datashader will have much to offer you. Instead, you could use the vectorized Labels element of HoloViews ( http://holoviews.org/reference/elements/matplotlib/Labels.html ), designed for plotting large numbers of text labels along with their associated points. A million labels is likely to be pretty slow, so I'd try a few test cases first. The Matplotlib backend of HoloViews is likely to give better results if you want a static PNG output.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM