Skip to main content
Question

Distance to coastline

  • April 12, 2024
  • 7 replies
  • 110 views

gael123
Contributor
Forum|alt.badge.img+1

Hi All I have a point distance data set in a parquet file with x y coordinates and a geom column with geometry encoded in hex binary and i have line data for coastline I want to calculate distance between these points and the coast polyline .In my workflow am using geometryreplacer to get the geometry then projecting both layers using csmapProjector then using neighborfinder but am getting unexpected results ...is there a better approach 

7 replies

liamfez
Influencer
Forum|alt.badge.img+44
  • Influencer
  • April 12, 2024

Could you provide more information? Examples of the data and the unexpected results would be helpful.


milo89
Enthusiast
Forum|alt.badge.img+26
  • Enthusiast
  • April 12, 2024

More information would definitely be useful.

That said, my most common check with using neighborfinder is what projection is your data in. The results will be in the projection units, so if your data is in degrees your ‘_distance’ result will also be in degrees.


gael123
Contributor
Forum|alt.badge.img+1
  • Author
  • Contributor
  • April 12, 2024

below is my workflow and the results the distance column is very similar no difference between points even though there should be ….the points are address points from different location I am expecting distance to vary 


milo89
Enthusiast
Forum|alt.badge.img+26
  • Enthusiast
  • April 12, 2024

Dealing with GNAF is always fun. 😀

So you’re either working in GDA94 or GDA2020 depending on which one you downloaded and then reprojection to a LCC. Can you try simply using a VertexCreator (it probably creates a geometry automatically from the reader) with the x, y and then show the output attributes of the neighborfinder (E.g. “_distance”).

You can also troubleshoot the results by creating a line to see the distance it’s measuring by using a VertexCreator with “Add Point” and the candidate x,y values.


gael123
Contributor
Forum|alt.badge.img+1
  • Author
  • Contributor
  • April 12, 2024

yeah I am reprojecting it to espg 7845  the thing is I used the same dataset with gnaf with the same workflow to calculate distance to another dataset of points and this worked but it doesn’t seem to work with coast data maybe because it is multi line as well 


redgeographics
Celebrity
Forum|alt.badge.img+62

Since your coordinate system uses degrees as the unit, and 1 degree can be (depending on your position on earth and the direction you’re measuring in) as large as 111 kilometers, your distances probably would be very similar if the points are close together.

Try reprojecting to an equidistant coordinate system (LCC is conformal, so it preservers shapes rather than distances, so not a very good choice anyway)


milo89
Enthusiast
Forum|alt.badge.img+26
  • Enthusiast
  • April 12, 2024

Since your coordinate system uses degrees as the unit, and 1 degree can be (depending on your position on earth and the direction you’re measuring in) as large as 111 kilometers, your distances probably would be very similar if the points are close together.

Since it’s in EPSG 7845 (GDA2020 - GA LCC) when it gets to the NeighborFinder, it should be in metres.

It would be useful to see what the results are from the NeighborFinder.