Today, when I used the rbind function in R language, this error occurred, and I couldn’t find the error after searching for a long time.
The reason for this mistake:
1. The data type used is data.frame
2. The header files for the rows to be merged are different
Solution: change the data to matrix, and you can do it. In addition, when you read the data, add the data header=FALSE, which is also ok. I tried it, but it is hard to use, so I changed it to matrix.
Error name: Error in match. Names (CLABS, names(XI)) : Names do not match previous names
The reason for this mistake:
1. The data type used is data.frame
2. The header files for the rows to be merged are different
Solution: change the data to matrix, and you can do it. In addition, when you read the data, add the data header=FALSE, which is also ok. I tried it, but it is hard to use, so I changed it to matrix.
Error name: Error in match. Names (CLABS, names(XI)) : Names do not match previous names