Skip to content

Instantly share code, notes, and snippets.

@halbuki
Created September 6, 2022 11:14
Show Gist options
  • Save halbuki/b732696f004e428cfd2cd0b14adc1278 to your computer and use it in GitHub Desktop.
Save halbuki/b732696f004e428cfd2cd0b14adc1278 to your computer and use it in GitHub Desktop.
Excel Lambda functions for Power Query Number functions
/* USE NAMESPACE "Number" */
Abs = LAMBDA(_number, ABS(_number));
Acos = LAMBDA(_number, ACOS(_number));
Asin = LAMBDA(_number, ASIN(_number));
Atan = LAMBDA(_number, ATAN(_number));
Atan2 = LAMBDA(_y, _x, ATAN2(_x, _y));
Cos = LAMBDA(_number, COS(_number));
Cosh = LAMBDA(_number, COSH(_number));
Exp = LAMBDA(_number, EXP(_number));
Factorial = LAMBDA(_number, IF(_number=1,1, _number * Number.Factorial(_number -1)));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment