Search code examples
rrbind

Error number of columns of result is not a multiple of vector length (arg 1) in R


I've got the upper error message error when trying to execute the following code

Nome_Dos_Formadores <- rbind(V_Nome_Dos_Formadores$`Nome do Formador`, N_Nome_Dos_Formadores$`Nome do Formador`)

Can you help me solving this error?


Solution

  • We would need to see results of str on those dataframes to know for sure. You code was only giving vectors to rbind. Generally people would want to use rbind for either matrices or dataframes. Perhaps you actually want:

    Nome_Dos_Formadores <- rbind(V_Nome_Dos_Formadores, N_Nome_Dos_Formadores)