I have uploaded a csv file, like the following:
datamap <- read.csv(file = "TheWorlds50BestRestaurants2018.csv", header = TRUE, sep = ",")
I want to put that dataset into a data frame. However, I have problems with the following sentence
mimapa <- data.frame(Year = datamap$Year,Ranking = datamap$Ranking,
Name = datamap$Name, City = datamap$City, Country = datamap$Country,Latitude = datamap$Latitude,Longitude = c(datamap$Longitude))
The error is:
Error in data.frame(Year = datamap$Year, Ranking = datamap$Ranking, Name = c(datamap$Name), : arguments imply differing number of rows: 0, 50
Please help me with that error, Thank you.