transformation.transformations.fare_metrics¶
Classes¶
Base Transformation to be inherited from while defining the transformations |
Module Contents¶
- class transformation.transformations.fare_metrics.FateMetricTranfromation¶
Bases:
transformation.transformations.base.BaseTranformationBase Transformation to be inherited from while defining the transformations
- apply(df: pyspark.sql.DataFrame) pyspark.sql.DataFrame¶
Calculate simple fare metrics as fare per km and fare per minute :param - df: the dataframe to extract informations from :type - df: DataFrame
- Returns:
the enriched dataframe
- Return type:
res (DataFrame)