Labels and Prompts:
The script loads all the numbers from file into a row vector. It then splits the vector; it stores the initial element that is the experiment number in a variable exper_no, rest of the vector in a variable data (the rest being from the next element to the end). It then plots the data, by using sprintf to generate the title which includes the experiment number as shown in the figure.
The other way of completing this (in script or function) would be as shown:
fprintf('%s, Enter your id #: ',username);
id_no = input('');
Note that the calls to the sprintf and fprintf functions are similar except that the fprintf prints (therefore there is no requirement for a prompt in the input function) while the sprintf generates a string which can then be exhibited by the input function. In this situation by using sprintf it seems clearer than using the fprintf and then having an empty string for the prompt in input.