Remove special characters from column header of dataframe

 import dataiku
import pandas as pd

d_dataset=dataset("abc")
d_df=d_dataset.get_dataframe()

d_df.columns=d_df.columns.str.replace("[$_() ]".'')

df_output=dataiku.Dataset("df_output")
df_output=write_with_schema(df_output)

Note:- Dataframe name should be same when you apply replace function as amrked in yellow.

Comments

Popular posts from this blog

Exponential Value parsing in SQL

Root path does not exist