Python is Finally in Excel! 🐍


3 things we’re covering today:

  • Microsoft’s huge Python update
  • A new way to connect Power BI to Excel
  • What I learned from When the Body Says No.

🐍 Python is Coming to Excel!!!

video preview

Microsoft just dropped a bombshell: Python code, yes, real Python, can soon be your partner-in-crime within Excel spreadsheets.

Just summon the new PY() function, and voilà! You've got Python's superpowers at your fingertips. Here’s my video all about it.

This feature is currently free to test in Microsoft 365 Insiders - you’ll find Python in the Formulas tab in the Excel Ribbon.

You get a few Python libraries already ready for you to use: pandas, matplotlib, seaborn, statsmodels and NumPy. You can import other libraries as needed.

And keep in mind:

  1. You don’t need any local installation of Python. Microsoft has partnered with Anaconda so Python runs securely on the Microsoft Cloud.
  2. You can use Python code on data that’s larger than Excel rows. You just need to connect to the data via Power Query and then load to Python and work with it. If you decide to spill the results to the grid, then it needs to fit on the sheet and nothing should be blocking it, otherwise you’ll get #SPILL error.
  3. Microsoft hasn’t officially stated whether this feature will be free or not in the future. They’ve just stated that it is free to use in Insiders (Beta) version of Excel - so we don’t really know what they’re planning there.

Now, how can you use Python in Excel in practical terms?

A few ideas:

  • Design charts that were difficult if not impossible to create in Excel.
  • Find and replace text based on a pattern - here the Regular Expression library is amazing!
  • Unpivot and perform complex queries on data.

Exciting times ahead!

🤠 The Active Cell - An Excel Training Camp in Vegas!

This year's Excel & Financial Modeling Training Camp called “The Active Cell” is happening in Las Vegas, December 7th - 9th.

If you happen to be in the area or fancy a trip to Vegas, you’ll want to attend this event. It’ll be 3 days filled with insights, inspiration, and networking opportunities with Excel enthusiasts from around the globe 🌎

Unfortunately I can't be there, but 25 Excel expert colleagues like Jon Acampora, Oz Du Soleil and Diarmuid (the LeBron James of Excel) will be speaking at the event.

Secure your place and book your tickets here, using the code LEILA10 for 10% off.

🤓 Other Geeky News

📈 PowerBI - New ways to create tables in Excel connected to Power BI
Microsoft are introducing an exciting new feature that makes it easier to add PowerBI data straight to your Excel workbook! We’ve been waiting for this a long time.

Here's how to get started:

  • Insert a Connected Table without leaving Excel by following these steps: Data Ribbon → From Power Platform → From Power BI (Microsoft)
  • This launches the Power BI Datasets side pane in Excel. From there, click Insert Table to create a connected Power BI table directly in Excel.

You can then choose from a range of options to select your fields and set up filters.

📊 Excel - A New Look for the Formula Bar

Microsoft have introduced monospaced font for the Formula Bar, to improve readability, error detection, and cross-platform consistency, which is great.

Here’s how it looks in practice:

🧭 Edge - Microsoft Edge for Business Now Available

Microsoft has released a work-focused version of its Edge browser. This lets users switch between dedicated work and personal browser windows (with separate caches and storage locations), to improve security and privacy. It's available on various devices and automatically applies to those using an Entra ID.

No more crossover between work and private life!

💚 My Favorite Things

📖 Book - When the Body Says No by Gabor Mate.

I love my job and love what I do. I talked about the relief of leaving corporate and starting my own business in this article.

But I still fall into the trap of feeling that I need to do more. That whatever I’m doing isn’t enough.

When the Body Says No made me realize how important it is to pay attention to my emotional state. It helped me understand myself better and improve my overall well being. Thank you to Veronika on LinkedIn for the recommendation. There are lots of great recommendations in the comments section of this post, which I’m working through.

🚀 Power Stories

Amazing work on completing our Fast Track to Power BI course Valentina! And thank you for the great review 💚

Got a success story about using your XelPlus skills? I’d love to hear it! Hit reply to share the details, and inspire other students 😇

See you next week,

Leila

Want more?

▶️ Subscribe on YouTube

🖇️ Follow me on LinkedIn

🥇 Join 400,000+ students in our courses

📣 Want to sponsor XelPlus Weekly? Get in touch here.

This newsletter contains affiliate links, which give us a small commission on any purchase made at no cost to you. This helps us run XelPlus Weekly and bring you updates like this. Thank you for your support!

Leila Gharani - XelPlus

XelPlus is a leading online education company, providing training courses for Excel, Power BI, Finance, and Google Sheets. XelPlus’ bestselling courses are popular among financial analysts, CFO’s, and business owners. Technology is changing fast. We help our members turn confusion into confidence with every skill learnt.

Read more from Leila Gharani - XelPlus

Pie charts get a bad rep. And honestly? Fair. I'm not a total hater. Two or three slices and a pie chart can tell a perfectly good story. But here's what actually happens in that meeting room when you've got 8+ slices on screen. People glance at the legend, look back at the chart... and have absolutely no idea what they're looking at. They won't say that, of course. Instead, the room either moves on a little too quickly or starts asking questions the chart should have already answered. Either...

Uh-oh. Embarrassing typo in the file name. And there's 50 of them. 🫨 Individual contracts about to go out to clients. You could rename them one by one. Or you could fix the whole mess in five seconds using something already built into Windows. No downloads.No complicated setup. Just PowerShell. 👉 I show you exactly how here. (BTW, if PowerShell doesn't pop up after typing the name in Explorer, try powershell.exe.) And if typing commands makes you nervous, there’s a drag-and-drop option built...

Shared Excel files are great until your whole team needs to work on it at once. You filter for your tasks. Your colleague filters for theirs. Now your filter's gone. You filter again. They filter again. 😤 It's like fighting over the TV remote, except it's a spreadsheet so more annoying. The fix: Sheet View. Go to View tab > Sheet View > New. You'll notice the column and row headers change to black. Give it a name. This way you can reuse it later. Just type over the "Temporary View". Now...