Microsoft is bringing Python to Excel
Microsoft is bringing Python to Excel
Microsoft today announced the public preview of Python in Excel, which will allow advanced spreadsheet users to combine scripts in the popular Python language and their usual Excel formulas in the same workbook.
This feature will first roll out to Microsoft 365 Insiders as part of the Excel for Windows beta channel. Yet while the feature will first only be available in the desktop version of Excel, Microsoft notes that the Python calculations will run in the Microsoft Cloud. Python runs perfectly well on any modern PC, so I’m not sure why Microsoft went the cloud route here.
“Now you can do advanced data analysis in the familiar Excel environment by accessing Python directly from the Excel ribbon,” Stefan Kinnestrand, the GM for Modern Work at Microsoft, explains. “No set up or installation is required. Using Excel’s built-in connectors and Power Query, you can easily bring external data into Python in Excel workflows.”
Microsoft partnered with data science platform Anaconda to bring this feature to life. The company is using the Anaconda Python distribution — running in Azure — to bring the most popular Python libraries to Excel, including the likes of Matplotlib and seaborn for data visualization.
To try this out, you’ll have to join the Microsoft 365 Insider Program and opt for the beta channel to get the latest Excel builds. From there, it’s just a question of selecting “insert Python” in the Formulas ribbon to get started.
It’s worth noting that there have long been libraries that allowed Python users to work with Excel files, as well as (paid) Excel add-ons like PyXLL that bring Python’s functionality to Microsoft’s spreadsheets, too.