Code Monkey home page Code Monkey logo

Comments (7)

chgrl avatar chgrl commented on June 30, 2024

Uh - when there's time, why not... :-)

from leafletr.

cjtexas avatar cjtexas commented on June 30, 2024

That would be awesome! I tried to figure out how to incorporate the additional functionality within your brew files but soon realized that my lack of expertise in Javascript/HTML (Leaflet in particular) was going to present some pretty large hurdles. Thanks for bridging the gap for R programmers 👍

from leafletr.

chgrl avatar chgrl commented on June 30, 2024

By the way, what do you want to do exactly? As leafletR is for visualizing your (R-) data, what shall the labels show - properties of the data, like a mouseover-popup? Or do you want to add extra markers/shapes with labels?

from leafletr.

cjtexas avatar cjtexas commented on June 30, 2024

Primarily, the former; I'd love to be able to choose either a static label or mouseover-popup and add that to an existing layer.

from leafletr.

tiernanmartin avatar tiernanmartin commented on June 30, 2024

+1 for the ability to add extra markers/shapes with labels!

It would be useful for adding static identification information to maps when the mouse-over popup is already dedicated to revealing other information.

For example, I'm creating a map of census data which shows a choropleth at the tract level. I'm utilizing mouse-over popup to provide detailed information about each individual census tract. However, when the viewer is zoomed out it would be useful to clearly identify the different counties – that's where this static label feature would help me out.

Thanks for the great package!

from leafletr.

chgrl avatar chgrl commented on June 30, 2024

Hi @onehundredpercenttexan and @tiernanmartin,
I put some work into this and now you can use labels.

library(leafletR)
dat <- toGeoJSON(data=quakes[1:10,], dest=tempdir())
map <- leaflet(data=dat, dest=tempdir(), popup="stations", label="mag")
map

Unfortunately it does not work with lines and polygons. Seems to be a problem of the plugin. Mayby @jacobtoye can tell us, whether Leaflet.label works with GeoJSON-polygons loaded via query.

Christian

from leafletr.

chgrl avatar chgrl commented on June 30, 2024

I close this for now...

from leafletr.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.