Updated save function to write the actual names of the stimulus used in
the stimref.txt file, i.e., those that are used in the stimdb.