. Advertisement .
..3..
. Advertisement .
..4..
I get “error in match.names(clabs, names(xi)) : names do not match previous names” error when trying to add a make Unique IDs argument to rbind. Spatial Polygons Data Frame for situations when the polygon IDs are identical. Here is the detail of the error I got
> do.call("rbind",xd.small)
Error in match.names(clabs, names(xi)) :
names do not match previous names
Please give me some advice to solve this problem.
The cause: The first dataframe’s names (column name) are not the same as the second.
Solution: You can force them to agree to the same names if they don’t care about the names in the 4th or 3rd columns of the second Df.
It is easy to use
unname()
: