ydata-profiling
ydata-profiling copied to clipboard
Variable Types to Dataframe
Proposed feature
It would be really useful to get a simple datafame containing the Variable name and the inferred variable type.
Can we please work on this?
Maybe we can learn from featuretools or other feature engineering package
@the-whopper I'm thinking that this might be a faster solution instead of creating a new feature for it.
df = pd.DataFrame({
'vartype_numeric': [1, 2, 3],
'vartype_bool': [True, False, True],
'vartype_datetime': pd.to_datetime(['2021-01-01', '2022-01-01', '2023-01-01']),
'vartype_unsupported': pd.to_timedelta([1, 2, 3], unit='days'),
'vartype_categorical': pd.Categorical([1, 2, 3])
})
report = ProfileReport(df)
summary_df= pd.DataFrame(report.get_description()['variables'])
summary_df