Closed beau-mind closed 6 years ago
df = pd.DataFrame({'x': [0, 1, 2, 3, 4, 5], 't': [1, 2, 3, 4, 5, 6]}) df >> define(('z','str(x)'))
produces wrong output. I can do this using df['x'].astype(str) in Pandas, but will this be supported by Plotnine?
df['x'].astype(str)
It the correct output, although not what the user intends.
These are equivalent
df >> define(('z','str(x)')) df['z'] = str(df['x']))
Try
df >> define(z='x.astype(str)')
produces wrong output. I can do this using
df['x'].astype(str)
in Pandas, but will this be supported by Plotnine?