Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Properties changing in time #18

Open
damylen opened this issue Apr 5, 2020 · 2 comments
Open

Properties changing in time #18

damylen opened this issue Apr 5, 2020 · 2 comments

Comments

@damylen
Copy link

damylen commented Apr 5, 2020

Is it possible to use linked-places to only change the properties for a specific time period? In my case the geometries stay the same (municipalities) and I only want to change some sensor data, stored in properties.

@kgeographer
Copy link
Contributor

An interesting question and food for thought. As I understand, this would involve including a when element within one or more of a Feature's properties, e.g. something like:

"features": [
  { "@id": "http://mygaz.org/places/p_12345",
    "type": "Feature",
    "properties":{
      "title": "Abingdon (UK)",
      "ccodes": ["GB"],
      "mymeasure": [
      	{ "value": 12.34, 
      	  "when": {"timespans":[{"start":{"in":1832}}]}
      	},
      	{ "value": 34, 
      	  "when": {"timespans":[{"start":{"in":2020}}]}
      	}
      ]
    },

From the standpoint of the GeoJSON spec, this is perfectly valid -- and it would not break implementations supporting GeoJSON or Linked Places. See popup boxes in this gist.

What to do with that data would be up to individual software applications...but that is the same issue with many other elements within Linked Places. For example, if such a dataset were uploaded to @WHGazetteer, the mymeasure property would be ignored.

HTH.

@damylen
Copy link
Author

damylen commented Apr 12, 2020

Thank you for your thoughts.... Had something similar in mind. From a performance perspective there would be a reason not to include the 'when' for each property, especially if you many features, with many properties that refer to the same dates.

Your issue with software applications is real. When implementing this in Mapbox (JS/GL), I noticed that they only support primitive types as property values. So a nested JSON object is serialized a string.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants