actio_python_utils.spark_functions.convert_chromosome¶
- actio_python_utils.spark_functions.convert_chromosome(self, current_column_name, new_column_name=None)[source]¶
Return a PySpark dataframe with
current_column_name
(containing human chromosomes) with a new column,new_column_name
(defaulting to overwriting the original), with the chromosome cast as an integer.- Parameters:
self (
DataFrame
) – The dataframe to usecurrent_column_name (
str
) – The column name to castnew_column_name (
Optional
[str
], default:None
) – The new column name to use
- Return type:
DataFrame
- Returns:
The processed dataframe