[[TranslatedPages(outdated=The example screenshots need to be retaken with bigger node render setting.)]] = Tools > Merge Nodes = [[PageOutline(2-10,Table of Contents)]] [[JOSMImage(mergenodes,48,link=,middle,margin-right=20)]] ''Keyboard shortcut:'' **`M`** **Merge nodes into the oldest one.** * The order of [wikitr:/Help/Action/Select selection] matters, as the remaining target node will keep the position of the last selected one. * The [wikitr:/Help/Concepts/Object#ObjectId object id] and [wikitr:/Help/Concepts/Object#ObjectHistory object history] of the oldest node with at least one parent will be preserved. If no parent object exists, the oldest node with lowest, positive id will be used (see #17866). * Ways will be silently deleted if their child node number drops below two, see [#WaysToDeleteStillInUse below]. * All [wikitr:/Help/Concepts/Object#Tags1 tags] with only a single value and all relation memberships from all nodes will be added and the [wikitr:/Help/Action/CombineWay#TagsMembershipsConflictDialog Tags/Memberships Conflict Dialog] will open if manual decisions are needed. In normal user mode it will additionally warn before adding any tag or membership the nodes do not have in common, like Combine Ways, see [wikitr:/Help/Action/CombineWay#CombineConfirmation Combine Confirmation]. == Can't merge because way still in use == #WaysToDeleteStillInUse The nodes you merge may be part of [wikitr:/Help/Concepts/Object#Ways ways]. If you merge them these parent ways may loose one or more of their nodes. In some cases the number of nodes left in these ways may drop below two. Ways with less than two nodes are invalid and JOSM tries to delete them. In some cases, though, a way to be deleted could still be in use, for instance, because a relation is referring to it. JOSM aborts merging nodes in these cases. Instead, it displays the following warning message: [[Image(warning-way-still-in-use.png,link=)]] Click on ''Abort Merging'' to close the dialog. The selected nodes are not merged. == Target position depends on last selection and advanced setting == === Advanced Preferences ===#AdvancedPreferences One of 3 modes can be set in the [[JOSMImage(preferences/advanced,link=,24,middle)]] [wikitr:/Help/Preferences/Advanced advanced preferences] with the {{{merge-nodes.mode}}} key: ||= **Mode setting** =||= **Description** =|| || `merge-nodes.mode=0` || default and simple: **last selected node will be used as position of resulting node**. || || `merge-nodes.mode=1` || to average locations of all selected nodes. || `merge-nodes.mode=2` || weighted average where nearby nodes have lower weight than remote. || Before merge (initial state): [[Image(before merge.png,50%,link=)]] * After merge with `merge-nodes.mode=0` (latest selected node is important) (''one of 9 positions, depending on the last node in selection'') * After merge with `merge-nodes.mode=1` (without weight) [[Image(after merge-nodes.mode=1.png,60%,link=)]] * After merge with `merge-nodes.mode=2` (weighted average): [[Image(after merge-nodes.mode=2.png,60%,link=)]] == See also == * [[JOSMImage(mapmode/move/move)]] [wikitr:/Help/Action/Select Select Move] * [[JOSMImage(mapmode/improvewayaccuracy)]] [wikitr:/Help/Action/ImproveWayAccuracy Improve Way Accuracy] - over time many mappers switch to this tools instead of manually selecting-and-moving each node * #6696 - patch about merge-nodes.mode ---- Back to [wikitr:/Help/Menu/Tools Tools menu] \\ Back to [wikitr:/Help Main Help]