# data from here http://lop12.edu.vn/download-toan-bo-diem-thi-thpt-quoc-gia-2016-tai-120-cum-thi/
library(readxl)
library(Hmisc)
library(stringr)
library(dplyr)
path_xl <- dir("c:/todel/a",full.names = TRUE) # create a vector of path to xlsx file
vnname_list <- lapply(path_xl,read_excel) #read all xls and add it to ten name is stored as a list
vnname <- do.call("rbind", vnname_list) # combine
vnname <- as_data_frame(ten)
vnname$ho <- word(vnname$hoten,1) # split 1 word into vnname$ho
ten <- tally(group_by(ten, ho), sort = TRUE)