Chapter10
Chapter10
© NIIT Slide 1 of 9
Objectives
By the end of this session, you should be able to understand:
• Using pip package manager
• Working with XLS files – pyexcel_xls & xlsxwriter
© NIIT Slide 2 of 9
XLS
• Spreadsheets are a very commonly used tool for a lot of data
crunching and day to day office tasks of reporting and presenting
analysis.
Let us explore how to make your python program work with the data
that is stored in an XLS file both in terms of reading as well as writing.
© NIIT Slide 3 of 9
XLS
Module : pyexcel_xls
© NIIT Slide 4 of 9
XLS
• Writing to an XLS file using pyexcel:
© NIIT Slide 5 of 9
XLS
• Reading an XLS file using pyexcel:
© NIIT Slide 6 of 9
XLS
Modulename : XlsxWriter
© NIIT Slide 7 of 9
xlsxwriter : Introduction
import xlsxwriter
workbook = xlsxwriter.Workbook('d:\\test.xlsx')
worksheet = workbook.add_worksheet()
workbook.close()
© NIIT Slide 8 of 9
xlsxwriter
Demonstrations to include – Using formulae, formatting, charts etc.
Further information:
http://xlsxwriter.readthedocs.io
© NIIT Slide 9 of 9