This is my first time working with R.
I have a table with 3 columns and 12090 rows (156 bacteria). The first two columns are names of bacteria and the last column is a number indicating relatedness between the organisms (based on a kind of genome similarity). example would be (made up numbers):
bacteria1 bacteria2 0.25846
bacteria1 bacteria3 0.35986
bacteria2 bacteria1 0.57896
bacteria2 bacteria3 0.54596
bacteria3 bacteria1 0.23659
bacteria3 bacteria2 0.36528
I would like to be able to neighbor join these into a phylogenetic tree of sorts. I see that 'nj' needs a distance matrix to do this. How would I convert this into a distance matrix or usable format? (The numbers are already distance so there shouldn't be any math being done) I've tried as.dist() and as.matrix() and reshape() but being new I may have done everything wrong. (reshape may be what I need..)
Or if anyone knows how to make these into a tree through other means that would be grand.
Thanks for any help.