Transformer

class zvt.contract.factor.Transformer

Bases: Indicator

__init__() None
transform(input_df: DataFrame) DataFrame

input_df format:

                          col1    col2    col3    ...
entity_id    timestamp
                          1.2     0.5     0.3     ...
                          1.0     0.7     0.2     ...

the return result would change the columns and keep the format

Parameters:

input_df

Returns:

transform_one(entity_id: str, df: DataFrame) DataFrame

df format:

             col1    col2    col3    ...
timestamp
             1.2     0.5     0.3     ...
             1.0     0.7     0.2     ...

the return result would change the columns and keep the format

Parameters:
  • entity_id

  • df

Returns: