I had a database with the following column names (each one correspond to an observation of an individual in different years, i.e. year 1, year 2):
Session <- c("Evidims_01_001_1", "Evidims_01_001_2", "Evidims_01_001_3", "Evidims_01_002_1", "Evidims_01_002_2", "Evidims_01_003_1", "Evidims_01_003_2" "Evidims_01_003_3", "Evidims_01_003_4", "Evidims_01_004_1")
My idea is to create a wide table, but first I want to delete the strings: "Evidims_0x_00x_y" and just keep the last number in each of the names, ie "1", "2".
Thanks in advance!