def compute_feature_label(self, f): if f.type != "original" and show_locations: return str(int(f.location.start)) elif show_feature_labels and f.type == "original": return BiopythonTranslator.compute_feature_label(f) else: return None
def compute_feature_label(self, feature): if feature.type == 'restriction_site': return None elif feature.type == "CDS": return "CDS here" else: return BiopythonTranslator.compute_feature_label(self, feature)
def compute_feature_label(self, feature): if abs(feature.location.end - feature.location.start) > 100: label = BiopythonTranslator.compute_feature_label( self, feature ) return abreviate_string(label, 10) else: return feature.qualifiers.get("enzyme", None)
def compute_feature_label(self, feature): if self.is_source(feature): return "".join(feature.qualifiers["source"]) elif abs(feature.location.end - feature.location.start) > 100: label = BiopythonTranslator.compute_feature_label(self, feature) return abreviate_string("".join(label), 30) else: return None
def compute_feature_label(feature): if AssemblyTranslator.is_source(feature): return feature.qualifiers['source'] elif abs(feature.location.end - feature.location.start) > 100: label = BiopythonTranslator.compute_feature_label(feature) return abreviate_string(label, 30) else: return None
def compute_feature_label(self, f): is_edit = f.qualifiers.get("is_edit", "false") if "true" in [is_edit, is_edit[0]]: return None default = BiopythonTranslator.compute_feature_label(self, f) label = None if (f.type != "misc_feature") else default if label == "misc_feature": label = None return label
def compute_feature_label(self, feature): if "homology" in str(feature.qualifiers.get("label", '')): return None else: return BiopythonTranslator.compute_feature_label(feature)
def compute_feature_label(self, f): return BiopythonTranslator.compute_feature_label(f)[:20]
def compute_feature_label(self, feature): if feature.type == "CDS": # not sure if we need to label the gene as well, can be changed if needed return BiopythonTranslator.compute_feature_label(self, feature) return None
def compute_feature_label(self, feature): if feature.type not in ["CDS", "regulatory"]: return None else: return BiopythonTranslator.compute_feature_label(self, feature)
def compute_feature_label(self, f): label = BiopythonTranslator.compute_feature_label(self, f) if not f.qualifiers.get("is_a_breach", False): if len(label) > 20: label = label[:19] + "…" return label