Using the MAP function in google sheets with a custom function with a single formula

Google Sheets Tutorials · Intermediate ·📰 AI News & Updates ·1y ago

About this lesson

@redtailfanschool In this short video I demonstrate how to use the MAP function in a google sheet. In this case we are using a custom function (Mileage) on a sheet. The problem I was trying to solve is having a single formula in the sheet header row to calculate the mileage between two cities. ={"Mileage"; MAP($G$2:$G, $H$2:$H, $I$2:$I, LAMBDA(start, finish, rt, IFERROR(IF(rt = "Yes", mileage(start, finish) * 2, mileage(start, finish)),)))} The MAP formula allows me to set the three variables in a single formula.

Original Description

@redtailfanschool In this short video I demonstrate how to use the MAP function in a google sheet. In this case we are using a custom function (Mileage) on a sheet. The problem I was trying to solve is having a single formula in the sheet header row to calculate the mileage between two cities. ={"Mileage"; MAP($G$2:$G, $H$2:$H, $I$2:$I, LAMBDA(start, finish, rt, IFERROR(IF(rt = "Yes", mileage(start, finish) * 2, mileage(start, finish)),)))} The MAP formula allows me to set the three variables in a single formula.
Watch on YouTube ↗ (saves to browser)
Sign in to unlock AI tutor explanation · ⚡30

Related AI Lessons

When AI Asks for More Electricity Than a Country Can Imagine
AI's increasing power consumption is causing concerns, learn why it matters for data centers and energy supply
Medium · AI
You Are Not Behind. The World Is.
You're not behind, the world is still adapting to AI, and it's okay to take your time to learn and grow
Medium · AI
Career choice with the advent of AI - pure Computer Science or learn software with a background of core engineering area
Learn how to choose between a Computer Science and Engineering career path or combining programming with a core engineering background in the age of AI
Dev.to AI
The AI Hype Cycle: Calm Before the Next Breakthrough?
Understand the AI hype cycle to anticipate the next breakthrough and make informed decisions
Medium · Programming
Up next
Generative AI
Alea IT Solutions
Watch →