def __init__(self, top=2.0, bottom=0.0, minicolor=color(.8, .8, .8), maincolor=color(0, 0, 0), align=None, text_align="middle", text_color=color(0, 0, 0), show=True, fixed_height=True, **options): Track.__init__(self, **options) self.top = top self.bottom = bottom self.minicolor = minicolor self.maincolor = maincolor self.text_align = text_align self.text_color = text_color self.show = show self.shown = show self.fixed_height = fixed_height if align != None: self.coords = alignlib.CoordConverter(align) else: self.coords = None self.multiscale = Multiscale(marginx=.5, marginy=.5, scalex=10, scaley=10)
def __init__(self, seqs, **options): options.setdefault("size", [0.0, 0.5]) Track.__init__(self, **options) self.seqs = seqs self.shown = False self.multiscale = Multiscale(marginx=.5, marginy=.5)
def __init__(self, xdata, ydata, **options): Track.__init__(self, **options) self.xdata = xdata self.ydata = ydata self.multiscale = Multiscale(marginx=.25, marginy=.25, scalex=4.0, scaley=4.0) self.shown = False
def __init__(self, aln, collapse=None, cols=None, color_bases=False, seqtype=None, show_color_bases=True, show_bases=True, show_labels=True, rowspacing=None, **options): Track.__init__(self, **options) self.size = [aln.alignlen(), len(aln)] self.multiscale = Multiscale(marginx=.5, marginy=.5) self.collapse = collapse self.show_color_bases = show_color_bases self.show_bases = show_bases self.show_labels = show_labels self.rowspacing = rowspacing self.always_color = False self.color_bases_vis = None if seqtype == None: self.seqtype = guessAlign(aln) else: self.seqtype = seqtype if color_bases == True: if self.seqtype == "dna": self.color_bases = dna_colors elif self.seqtype == "pep": self.color_bases = pep_colors else: self.color_bases = color_bases if collapse != None: assert collapse in aln.keys() cols = util.findneq('-', aln[collapse]) if cols != None: self.aln = alignlib.subalign(aln, cols) else: self.aln = aln
def __init__(self, win, start, end, height=20, bottom=0, unitstr="", minicolor=color(.8, .8, .8), maincolor=color(0, 0, 0), pos=[0.0, 0.0]): summon.VisObject.__init__(self) self.win = win self.start = start self.end = end self.height = height self.bottom = bottom self.pos = pos[:] self.minicolor = minicolor self.maincolor = maincolor self.multiscale = Multiscale(marginx=.5, marginy=.5, scalex=10, scaley=10)