I’d like to get some help with a work, but i don’t really know how to get to it. I have to make a distance matrix, froma a 3 column text, that looks like this :
AN51 AN50 88
AN52 AN50 167
AN52 AN51 125
AN53 AN50 81
AN53 AN51 93
AN53 AN52 170
AN54 AN50 120
AN54 AN51 119
AN54 AN52 117
AN54 AN53 66
The output is have to be a square shapet “2d” matrix
AN50 AN51 AN52 AN53
AN50 0 88 167 81
AN51 88 0 125 93
AN52 167 125 0 170
AN53 81 93 170 0
I tried the reading in from file with $0, and it finally read all the fields but in different alignment.
1 Answer