ETE Toolkit によって生成される出力画像のフォント フェイスの向きを変更したい: http://etetoolkit.org
何らかの理由で、下の図に示すように、回転と向きの変更はラベルに影響しません。
Jupiter ノートブックでこの例を生成するコードは次のとおりです。
from ete3 import Tree, TreeStyle
def draw_ete(newick):
t = Tree(newick)
ts = TreeStyle()
ts.scale = 5
ts.rotation = -90
ts.orientation = 1
return t.render("%%inline", tree_style=ts)
newick = """((p, e, a, s, ((e, _), p, o), r, r, i, d, g, (e, _)), (h, o, t), ((,, ↵), (p, e, a, s, ((e, _), p, o), r, r, i, d, g, (e, _))), (c, (o, l, d)), ((,, ↵), (p, e, a, s, ((e, _), p, o), r, r, i, d, g, (e, _))), ((i, n), _, t, h, ((e, _), p, o), t, (,, ↵), n, (i, n), (e, _), d, a, y, s, _, (o, l, d), .), ↵, ↵, (s, o, m, (e, _), l, i, k, (e, _), i, t, _), (h, o, t), ((,, ↵), (s, o, m, (e, _), l, i, k, (e, _), i, t, _)), (c, (o, l, d)), ((,, ↵), (s, o, m, (e, _), l, i, k, (e, _), i, t, _)), ((i, n), _, t, h, ((e, _), p, o), t, (,, ↵), n, (i, n), (e, _), d, a, y, s, _, (o, l, d), .));"""
draw_ete(newick)
また、出力を 1 行ではなく複数の行に分割できるかどうかも知りたいです。長いシーケンスは幅の広いスペースを必要とする傾向があるため、シーケンスを複数の行に分割することが実用的です。