def process_xml(xml_string): tp = TripsProcessor(xml_string) tp.get_complexes() tp.get_phosphorylation() tp.get_activating_mods() tp.get_activations() return tp
def process_xml(xml_string): """Return a TripsProcessor by processing a TRIPS EKB XML string. Parameters ---------- xml_string : str A TRIPS extraction knowledge base (EKB) string to be processed. http://trips.ihmc.us/parser/api.html Returns ------- tp : TripsProcessor A TripsProcessor containing the extracted INDRA Statements in tp.statements. """ tp = TripsProcessor(xml_string) if tp.tree is None: return None tp.get_complexes() tp.get_phosphorylation() tp.get_activating_mods() tp.get_activations() tp.get_activations_causal() return tp