Skip to main content
Format code
Source Link
Shunya
  • 2.5k
  • 4
  • 20
  • 36
> from pandas import * > x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) > x > > x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo > x.drop(['foo'], axis=1) 
from pandas import * x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) x x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo x.drop(['foo'], axis=1) 
> from pandas import * > x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) > x > > x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo > x.drop(['foo'], axis=1) 
from pandas import * x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) x x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo x.drop(['foo'], axis=1) 
added 60 characters in body
Source Link

from pandas import * x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) x

x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo x.drop(['foo'], axis=1)

> from pandas import * > x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) > x > > x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo > x.drop(['foo'], axis=1) 

from pandas import * x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) x

x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo x.drop(['foo'], axis=1)

> from pandas import * > x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) > x > > x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo > x.drop(['foo'], axis=1) 
Source Link

from pandas import * x = DataFrame({'foo':['a','b','c'], 'bar':[1, 2, 3]}) x

x['bar'] = x.bar.astype("str") + " " + "is" + " " + x.foo x.drop(['foo'], axis=1)