Skip to content

Instantly share code, notes, and snippets.

@ncalm
ncalm / excel-lambda-LEV.txt
Last active September 18, 2024 11:06
This Excel LAMBDA function calculates the Levenshtein distance between two strings
/*
LEV
Calculates the Levenshtein distance between two strings
Inputs
- a: a string to compare with b
- b: a string to compare with a
- [ii]: the [ii]th position in string a
- [jj]: the [jj]th position in string b
@ExcelRobot
ExcelRobot / CHOOSETABLECOLUMNS.lambda
Last active May 14, 2024 01:37
Choose Table Columns LAMBDA Function
/*
Name: Choose Table Columns (CHOOSETABLECOLUMNS)
Description: Similar to CHOOSECOLUMNS but can accept an array of column header names or
array of column indexes. If column headers are used, assumes first row of Table is
header row.
Author: Excel Robot (@ExcelRobot)
Category: Table
*/
CHOOSETABLECOLUMNS = LAMBDA(Table, ColumnsToSelect, LET(
FirstColumnToSelect, INDEX(ColumnsToSelect,1,1),
@ExcelRobot
ExcelRobot / multi-level data validation.lambda
Last active July 22, 2024 21:04
Multi-Level Data Validation LAMBDAS
/*
Name: Multi-Level Dropdown Validation (MultiLevelDropdownValidation)
Description: Returns the list of allowable values for a specific cell based on
the entries to the left.
Parameters:
tablename - name of the Excel table containing the data validation dropdowns.
header - table header cells from the first column with data validation to the column for which
to return list of values allowed.
keylisttable - reference to dynamic range containing the MultiLevelKeyLists lambda key lists table.
Source: Written by Excel Robot, inspired by Wyn Hopkins (https://www.youtube.com/watch?v=r0DTFodQYJQ&t=989s)
@CHatmaker
CHatmaker / BXL LAMBDA Reporting with Arrays
Last active April 7, 2024 15:06
5G functions for Excel for Reporting with Arrays
/* FUNCTION NAME: Aboutλ
DESCRIPTION:*//**Displays the URL to this module's Gist which includes documentation*/
/* REVISIONS: Date Developer Description
Mar 17 2023 Craig Hatmaker Copyright
Apr 17 2023 Craig Hatmaker Reorganizing and adding help
Jul 03 2023 Craig Hatmaker See nFoldCartProdλ and PriorDimProdλ
Jul 11 2023 Craig Hatmaker See UnPivotDetailλ
Feb 11 2024 Craig Hatmaker See UnPivotDetailλ
*/