phenopacket_mapper.utils.str_to_valid_id module

phenopacket_mapper.utils.str_to_valid_id.str_to_valid_id(s: str) str[source]

Converts a string to a valid id

This function converts a string to a valid id by replacing spaces with underscores and removing all other non-alphanumeric characters.

Parameters:

s – The string to convert to a valid id

Returns:

The valid id