Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Data Cleaning with Power BI

You're reading from  Data Cleaning with Power BI

Product type Book
Published in Feb 2024
Publisher Packt
ISBN-13 9781805126409
Pages 340 pages
Edition 1st Edition
Languages
Author (1):
Gus Frazer Gus Frazer
Profile icon Gus Frazer

Table of Contents (23) Chapters

Preface Part 1 – Introduction and Fundamentals
Chapter 1: Introduction to Power BI Data Cleaning Chapter 2: Understanding Data Quality and Why Data Cleaning is Important Chapter 3: Data Cleaning Fundamentals and Principles Chapter 4: The Most Common Data Cleaning Operations Part 2 – Data Import and Query Editor
Chapter 5: Importing Data into Power BI Chapter 6: Cleaning Data with Query Editor Chapter 7: Transforming Data with the M Language Chapter 8: Using Data Profiling for Exploratory Data Analysis (EDA) Part 3 – Advanced Data Cleaning and Optimizations
Chapter 9: Advanced Data Cleaning Techniques Chapter 10: Creating Custom Functions in Power Query Chapter 11: M Query Optimization Chapter 12: Data Modeling and Managing Relationships Part 4 – Paginated Reports, Automations, and OpenAI
Chapter 13: Preparing Data for Paginated Reporting Chapter 14: Automating Data Cleaning Tasks with Power Automate Chapter 15: Making Life Easier with OpenAI Assessments Index Other Books You May Enjoy

Creating custom functions

With proper planning and an understanding of parameters, you’re now ready to dive into creating custom functions in Power Query. This section will guide you through the process of building your custom function, including defining its structure, working with M code, and testing your function.

Defining the function structure

The structure of your custom function is crucial for its functionality and usability. Define the following aspects of your function:

  • Name: Choose a descriptive name for your function
  • Parameters: Specify the parameters your function will accept and their data types
  • Description: Provide a clear and concise description of what your function does
  • Result: Determine the expected result or output of your function

Writing M code

Power Query functions are created using the M language, which we touched upon earlier in this book. You’ll need to write M code to define your function’s behavior...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}