Newick format output is added, some bugs are fixed.