skbio.metadata.SampleMetadata.filter_ids#
- SampleMetadata.filter_ids(ids_to_keep)[source]#
- Filter metadata by IDs. - Parameters:
- ids_to_keepiterable of str
- IDs that should be retained in the filtered - Metadataobject. If any IDs in ids_to_keep are not contained in this- Metadataobject, a- ValueErrorwill be raised. The filtered- Metadataobject will retain the same relative ordering of IDs in this- Metadataobject. Thus, the ordering of IDs in ids_to_keep does not determine the ordering of IDs in the filtered- Metadataobject.
 
- Returns:
- Metadata
- The metadata filtered by IDs. 
 
 - See also