syntactic.make_names¶
- syntactic.make_names(obj: list[str] | str, unique: bool = True, smart: bool = False) list[str]¶
Make syntactically valid names out of character vectors.
Emulates R’s syntactic::makeNames() behavior.
- Parameters:
- Returns:
Syntactically valid name(s).
- Return type:
Examples
>>> make_names(["%GC", "1st sample", "hello world"]) ['GC', 'X1st_sample', 'hello_world']