Arguments Imply Differing Number of Rows

#I imported these datasets successfully

first_quarter <- read_csv("Divvy_Trips_2019_Q1.csv")
second_quarter <- read_csv("Divvy_Trips_2019_Q2.csv")
third_quarter <- read_csv("Divvy_Trips_2019_Q3.csv")
fourth_quarter <- read_csv("Divvy_Trips_2019_Q4.csv")

#then I tried to create a big data frame
Year_2021_Trips <- rbind(first_quarter, second_quarter, third_quarter, fourth_quarter)

#But the error displayed like this:-

Error in data.frame(first_quarter, second_quarter, third_quarter, fourth_quarter) :
arguments imply differing number of rows: 365070, 1108164, 1640719, 704055

Is anybody has a solution for this error?

I thank you in advance!

It looks like this should work.
Can you show us the result of

class(x_quarter)
dim(x_quarter)

with x being first up to fourth ?

You might also want to try the function bind_rows from dplyr instead of rbind

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.