Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

pandas add prefix zeros to column values

df['ID'] = df['ID'].apply(lambda x: x.zfill(15))
Comment

PREVIOUS NEXT
Code Example
Python :: df sort by column names 
Python :: how to define a class in python 
Python :: how to strip white space of text in python? 
Python :: pandas datetime to unix timestamp 
Python :: how to install python library 
Python :: fernet generate key from password 
Python :: restrict ticks to integers matplotlib 
Python :: python code for extracting data from pdf 
Python :: how to find index of maximum value in dataframe in python 
Python :: making your own range function in python 
Python :: axios django csrf 
Python :: getting input in python 
Python :: sortedcontainers sorteddict import 
Python :: how to plot box plot python 
Python :: how to make software in python 
Python :: flask structure 
Python :: time.sleep() python 
Python :: merge two columns name in one header pandas 
Python :: pandas rolling mean 
Python :: keras normalize 
Python :: Display head of the DataFrame 
Python :: break line in string python 
Python :: how to take out every even number from a list in python 
Python :: with open 
Python :: python dictionary pop key 
Python :: convert a string into a list 
Python :: plt delete space before axis 
Python :: how to add a linebreak in python 
Python :: python min value index from an array 
Python :: python staticmethod property 
ADD CONTENT
Topic
Content
Source link
Name
6+6 =