MATLAB: Way for matching letters and numbers in two files

characterscolumncommandfilesloopmatchnumbers

Hello,
I have a question about one code. I have two files. file1, has one column with numbers only. the second file (file2) has two column. in which the first column has numbers and the second columnn has letters/characters. I would like to add a new column in file1 which would have letters/characters, based on the file2 structure.
I send you some pics in order to see what I want to do.
file1
file2
final file
I attach the two files (final1.xlsx & file2.xlsx) and the final file (final_file.xlsx) I would like to create
could you help me please?

Best Answer

Not sure how file1 is involved. If you want to sort the cell array file2 based on the contents of column 1, use sortrows(ca, 1). If you need anymore help, attach the two files.