Clear objectives: After the municipal level plus a 'city' word
first step: Import data box
library(tidyverse)
consum <-
read_csv(
'C:\\Users\\Administrator\\Desktop\\DXYArea.csv'
)
View data
head(consum)
Step two: forming a word
consum$shi<-c('市')
The third step: using two combined function str_c
consum$cityName<-str_c(consum$cityName,consum$shi)
Step 4: adding a deleted
consum<-consum[,-16]
Look at the results: