3

Let's say I have 2 line layers (green & red, in the image below) and I need to transfer attributes from one layer (red) to another (green) by doing a Spatial Join. The layers are identical, but offset by a minuscule distance, b/c of some reprojection & geographic transformation -- something like 0.005 meters (5 mm).

Of course this is not even a meaningful offset for any real-world analysis issue, but for a Spatial Join, it seems it would prevent the lines from actually overlapping perfectly & thus the Intersect operation would transfer the wrong attributes.

Using "Within a Distance" w/ some similarly tiny distance would invariably capture not only the parallel green line that the red line was meant to be on top of, but the perpendicular green line as well.

It's hard to believe I'm really out of luck on such a simple operation & have to resort to some much more complex procedure, simply due to a less than 100% absolutely perfect overlap between 2 otherwise completely identical line layers. And I can't really imagine any workaround. Any ideas?? Thanks very much!

Image below!: enter image description here

4

In ArcGIS Desktop, you can use the Integrate Tool to move the vertices of two feature classes to be coincident within a certain threshhold distance.

As long as you are certain your verticies are very close and carefully set your threshold distance, you can then do a Spatial Join on geometries that are unique.

Note however, that this will change the geometries of both datasets slightly and in a manor that is difficult to control. This won't be a a huge problem since your error is so small, but it should be considered. I'd recommend running the tool while in an active edit session to give yourself an out if you find the resulting shift unacceptable.

  • Interesting, never had occasion to use this tool before. I'm working with an enormous dataset spanning much of North America, so this approach kind of scares me as it might be inaccurate in many places that I'll never find. The lines are streams, and b/c of the sinuosity, the threshold distance will be quite hard to choose as it varies a lot (but the offset is never much more than 1 cm I think). But definitely worth a try. – user14175 Dec 13 '13 at 21:45
  • If they are identical and only around 1cm off, you shouldn't have much trouble. I've used this technique on datasets that represented the same linear features but were digitized by different organizations, and ended up using a threshold of 10 ft (which got me the bulk of what I wanted, then I manually fixed the rest). The places I mainly saw errors with a threshhold that large were where a linear feature went into a Y fork, and the first vertices of each of the forks of the Y were within my threshold distance. Given the minimal error you ahve, this shouldn't be an issue. – DPierce Dec 13 '13 at 22:14
1

Buffer the source layer by a small amount (slightly greater than the offset between the layers). Do not merge or "dissolve" the buffers. Spatially join the buffer layer to the destination layer based on the "contains" relation.

  • To the person who downvoted and attempted to edit this answer: the spatial join recommended here does resolve the OP's question to "transfer attributes from one layer (red) to another (green) by doing a Spatial Join." It is something I have performed successfully over many years. – whuber Mar 24 '15 at 22:09
0

I know this is an old thread but in case someone else stumbles upon it like me: you can make two buffers on the layers, and then pairwise intersect (arcgis pro) and find the largest area of intersection for each segment.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.