Jump to content

 
Photo

Sample points based on grid

- - - - -

  • Please log in to reply
7 replies to this topic

#1
david17tym

david17tym

    Master Contributor

  • Validated Member
  • PipPipPipPip
  • 103 posts
  • Gender:Male
  • Location:North Wales
  • United Kingdom

Hello everyone,
I have an input dataset containing thousands of observation points.
I'd like to sample these using a 1km grid, extracting only 1 original point per km sq.
Can I do this maintaining the data as vectors?
Thanks,
Dave

#2
frax

frax

    Hall of Fame

  • Associate Admin
  • PipPipPipPipPipPipPip
  • 2,309 posts
  • Gender:Male
  • Location:Stockholm, Sweden
  • Interests:music, hiking, friends, nature, photography, traveling. and maps!
  • Sweden

How would you (the process) now which point to sample, if there are several in each cell? What software do you have at hand?
Hugo Ahlenius
Nordpil - custom maps and GIS
http://nordpil.com/
Twitter

#3
david17tym

david17tym

    Master Contributor

  • Validated Member
  • PipPipPipPip
  • 103 posts
  • Gender:Male
  • Location:North Wales
  • United Kingdom

Hi Frax,
The whole idea is to thin the dataset for presentation on a regional map, withoiut losing the main observable trends.
But I may be over simplifying the problem. Thinking about it some more I don't think I can automate this.
Dave

#4
Hans van der Maarel

Hans van der Maarel

    CartoTalk Editor-in-Chief

  • Admin
  • PipPipPipPipPipPipPip
  • 3,882 posts
  • Gender:Male
  • Location:The Netherlands
  • Interests:Cartography, GIS, history, popular science, music.
  • Netherlands

I have an input dataset containing thousands of observation points.
I'd like to sample these using a 1km grid, extracting only 1 original point per km sq.
Can I do this maintaining the data as vectors?


Yes, I once used FME in this fashion to thin out depth soundings. Per square kilometer we only kept the max and min value (this was for a product specifically aimed at pleasure yachting and it concerned depth soundings in the North Sea, away from any shallows that could potentially be dangerous).

The process involved creating a grid, overlaying the points on that and then calculating which ones were the min and max in their respective grid cell.
Hans van der Maarel - Cartotalk Editor
Red Geographics
Email: hans@redgeographics.com / Twitter: @redgeographics

#5
david17tym

david17tym

    Master Contributor

  • Validated Member
  • PipPipPipPip
  • 103 posts
  • Gender:Male
  • Location:North Wales
  • United Kingdom

That's the right idea Hans, but I think I'll lose some important trends using this random approach.
Back to the drawing board (actually digitising tablet)...
Dave

#6
Martin Gamache

Martin Gamache

    Ultimate Contributor

  • Associate Admin
  • PipPipPipPipPipPip
  • 980 posts
  • Gender:Male
  • Location:Washington DC
  • Interests:History of Topographic Cartography
    Topographic Mapping
    History of Relief Depiction
    Thematic Cartography
    Demographic Cartography
    Cartographic techniques, methods, and tools
    Orienteering
    Panoramic & Kite Photography
  • United States

Hawth's Tools has some sampling tools and allows you to create nice grids that overlay your data, do counts, sampling etc...

From there you have two methods:

1. You convert to a raster grid using some sort of statistic ( min, max, avg, mode, median, )and get a 1km grid with one value then output a point for each cell with that value?


2. You can also create am array of 1km squares, do a spatial join ( which allows you to select some statistics) assign that value to each grid square then convert the squares to a point.

#7
Hans van der Maarel

Hans van der Maarel

    CartoTalk Editor-in-Chief

  • Admin
  • PipPipPipPipPipPipPip
  • 3,882 posts
  • Gender:Male
  • Location:The Netherlands
  • Interests:Cartography, GIS, history, popular science, music.
  • Netherlands

That's the right idea Hans, but I think I'll lose some important trends using this random approach.


I agree on that. For the goal I was doing it for, that wasn't so much an issue (if your boat's keel is 3 feet below the surface, you really don't care whether it's 100 or 102 feet deep right there...)

An alternative approach, but I have to admit I never explored this idea further, might be to treat your data as elevations (if possible) and generate a TIN. By playing with the surface tolerance you might be able to focus on the trends in the data. Just a thought...
Hans van der Maarel - Cartotalk Editor
Red Geographics
Email: hans@redgeographics.com / Twitter: @redgeographics

#8
frax

frax

    Hall of Fame

  • Associate Admin
  • PipPipPipPipPipPipPip
  • 2,309 posts
  • Gender:Male
  • Location:Stockholm, Sweden
  • Interests:music, hiking, friends, nature, photography, traveling. and maps!
  • Sweden

It would probably work decently to choose the median. You might want to collect some other statistics like the count of points per cell and min and max just to see what it looks like.
Hugo Ahlenius
Nordpil - custom maps and GIS
http://nordpil.com/
Twitter




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

-->