profile

Leila Gharani - XelPlus

Python is Finally in Excel! 🐍

Published 9 months ago • 3 min read

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

Helping you easily overcome data challenges with Excel & Power BI

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

Thinking VLOOKUP is dead now that we have XLOOKUP? Think again. It's still used across thousands of spreadsheets. It has some limitations, but if you're aware of them and use it correctly, you'll get the job done quickly. Also, this edition of Between the Sheets includes: Power tools making a difference Better technical answers from ChatGPT Solution for tab hoarders If you were forwarded this message, you can get the free weekly email here. 🎬 Master VLOOKUP for effortless reporting In my...

5 days ago • 4 min read

Today, we're diving deeper into Excel's View tab to show you some lesser-known, yet incredibly handy features that will change the way you manage your workbooks. Also in focus: sharing views in Excel for the web AI writing assist in any online text box OneDrive offline capabilities If you were forwarded this message, you can get the free weekly email here. Master the Window options in Excel's View tab A while ago we covered the magic of Freeze Panes. But there are other buttons in the View...

12 days ago • 4 min read

We’re almost done with our New Excel Business Charts Course and it’s looking great! I'm currently reviewing the final videos. Meanwhile, the team is busy finalizing the cheat sheets, lesson notes, and quick guides. This morning, I reviewed the lecture "How to Pick the Right Chart". And wow! It took me right back to my corporate job, staring at the screen, wondering, "How on earth do I make this data tell a story?!". There was SO MUCH to show. Picking the right chart might seem easy, but...

about 1 month ago • 4 min read
Share this post