Exporting PSS™E Results and Data to Excel Spreadsheets
Krishnat
Patil
Staff Software Engineer
krishnat.patil@siemens.com
In PSS™E version 31, ACCC, PV and QV analysis
results can be exported to excel spreadsheets using Excel Export
GUI, shown in Figure 1. This GUI is launched from PSS™E menu Power
Flow>Reports>Export to Excel or Start>Program>PSSE31>PSS™E Utilities>Export
to Excel.

Figure
1 - Excel Export GUI
The GUI
options as selected in Figure 1, exports ACCC contingency solution
results to eight sheets of a spreadsheet as illustrated in Figure
2.

Figure 2 - ACCC Results
Additionally there are two new python modules
"PSSEXCEL" and "EXCELPY" which provide convenient python functions
to export PSS™E results and data to excel spreadsheets from python
scripts. PSSEXCEL module retrieves PSS™E activity results using
python module PSSARRAYS, and then creates and populates excel
spreadsheets with those results. For example, following command
exports ACCC results from savnw.acc file to pssexcel_accc_savnw.xls
spreadsheet, as shown in Figure 2.
pssexcel.accc('
savnw.acc', ['s','e','b','i','v','l','g','p'],
xlsfile=' pssexcel_accc_savnw.xls')
EXCELPY is an auxiliary module that
provides python functions to create, populate and format excel
spreadsheets with any data. For example, following python script
retrieves bus numbers , name and base voltage from PSS™E case
in memory and populates savnw_busdata.xls spreadsheet as shown
in Figure 3.
import
excelpy
ierr, busnum = psspy.abusint(-1,2,'NUMBER')
ierr, buskv = psspy.abusreal(-1,2,'BASE')
ierr, busnam = psspy.abuschar(-1,2,'NAME')
testwbook = excelpy.workbook('savnw_busdata.xls')
testwbook.show()
testwbook.set_cell((1,1),'SAVNW BUS
DATA',fontStyle='bold',fontName='arial',fontSize=14,fontColor='red')
testwbook.set_range(2,1,['Number','Name','Base kV'],fontStyle='bold',
fontName='courier',fontSize=12,fontColor='blue')
brow, rcln = testwbook.set_range(3,1,busnum[0],transpose=True)
rcln += 1
brow, rcln = testwbook.set_range(3,rcln,busnam[0],transpose=True)
rcln += 1
brow, rcln = testwbook.set_range(3,rcln,buskv[0],transpose=True,numberFormat='0.0')
testwbook.save ('savnw_busdata.xls')

Figure
3 - Working Case Bus Data Exported to a Spreadsheet
Refer to help(pssexcel), help(excelpy), API manual and User manual
for further details and list of available functions from these
modules.
Download
document as .pdf
| Siemens Power Transmission
& Distribution, Inc., Power Technologies International
1482 Erie Boulevard | P.O. Box 1058 | Schenectady,
NY 12301-1058
Privacy
& Legal |
|