In [6]: df = Dataframe(dict(A = date_range('20130101',periods=10)))In [7]: dfOut[7]: A0 2013-01-01 00:00:001 2013-01-02 00:00:002 2013-01-03 00:00:003 2013-01-04 00:00:004 2013-01-05 00:00:005 2013-01-06 00:00:006 2013-01-07 00:00:007 2013-01-08 00:00:008 2013-01-09 00:00:009 2013-01-10 00:00:00In [8]: df['A'].apply(lambda x: x.strftime('%d%m%Y'))Out[8]: 0 010120131 020120132 030120133 040120134 050120135 060120136 070120137 080120138 090120139 10012013Name: A, dtype: object
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)