There is no direct function to convert a dendrogram to a text format such as above.
However, using the underlying data, you could store that data in a table. One of the features of the table data structure in MATLAB is you are able to specify headers for the columns.
If you wanted to write the data to a file, you could then use the "writetable" function, linked below.