Comments (4)
What to do about geocoding?
from mapsforus.
I was thinking of automating the geocoding step once an address is entered in that row. But I'm currently relying on the lack of a geocode to allow me to show several events at the same location in my list of concerts, but only show that location once on the map (rather than needlessly stack up markers).
If I do automate the geocoding (assuming that's possible, but it seems like it is), I'd probably then add a column for a "Hide from Map" flag to the Points sheet, and use that to determine whether or not to render a marker for that row.
Last thought is just that the form responses live on a different worksheet, and when the form is used, we could just always automatically generate a geocode based on the address, then copy that row and append it to the "Points" sheet (without the timestamp column). If people want address data without geocodes, they can edit directly on the spreadsheet. It's probably a rare case.
from mapsforus.
@oddlyaromatic What do you mean by "it seems like it is" possible to automate geocoding? TBH, I haven't looked into this at all, so I have no idea about whether or how to automate the geocoding.
from mapsforus.
If I remember it rightly, the geocoding function accepts 3 table cell references as arguments (or accepts an an array, where each element is an array of 3 cells, if multiple rows are selected) - the "source" cell containing the address, and the empty cells where it will put the latitude and longitude. The way I see it I would write a function that loops through all rows in the sheet and if the latitude and longitude fields are blank but the address field has data, run the geocoding function for that row. So the user doesn't have to select the fields and initiate the script. It could run on every edit, or on a timer, or whatever.
What I plan to do for my project is the solution where we do all that on a separate worksheet, where form results are stored, and then append to the main Points worksheet. That way, we don't accidentally mess with anything that was already set (or left blank on purpose) in the Points sheet. And the function could just run on every edit because an "edit" would be the form appending a complete row after somebody submitted it, not just a user keypress where the function would run many times for nothing.
When it's up and running I'll post the example and hopefully all will be working and make sense. Might be a little while. Maintaining this feature could be tricky, since moving or renaming columns would need an edit to the function, so I think I have a ways to go before this is a general solution.
from mapsforus.
Related Issues (12)
- Google Maps-like point information
- Integrate Field Papers?
- Show data sources
- TOU
- Layer consistency
- Blank row in spreadsheet breaks map HOT 2
- Add a link for people to contribute to the map?
- All links in map should open in _parent
- Decide on release strategy
- Add an option to the spreadsheet to disable single-finger panning
- Attributions
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mapsforus.