pypath.inputs.hmdb.proteins.mapping§
- pypath.inputs.hmdb.proteins.mapping(id_type_a: str, id_type_b: str, return_df: bool = False, head: int | None = None) dict[str, set[str]] | pd.DataFrame [source]§
ID translation input from HMDB.
Note: you can use this function for purposes other than ID translation tables, e.g. you can collect the molecular weights, pathways, etc. Though not all these options are guaranteed to work or result a meaningful output.
- Parameters:
id_type_a – An identifier type, see the ID_FIELDS set in this module, and keys in the SIMPLE_FIELDS dict.
id_type_b – Another identifier type, same options as for id_type_a.
return_df – Return a data frame instead of dict of sets.
head – Process the first N records only. Useful for peeking into the data.
- Returns:
Translation data between two types of identifiers.