A few simple calculations can be the difference between a perfect workflow automation and a frustrating tool that doesnāt do what you need it to.Ā
Make (formerly Integromat) gives you an extensive selection of math operations that you can use in any text field in your scenarios.Ā
You can use these functions to add numbers, round off a decimal point, find the average value in a set of numbers, or even generate a random value.Ā
In this post, weāll show you how to perform each of these functions with short, step-by-step tutorials. Weāll use a Slack module as an example, so the result of every function will be sent as a Slack message.Ā
Add numbers together
With the āsumā function, Make will calculate the sum of every number you enter between the parentheses. Hereās how it works:
ā¢ Open any text field in your scenario
ā¢ Select the X1 symbol to access math functions
ā¢ Click on the āsumā function to add it to your selected field
ā¢ Enter the numbers you want to add together, separated by semicolons
ā¢ Alternatively, you can enter an array of numbers to add together
ā¢ Run the module to output the sumĀ
Round decimal values to whole numbers
Makeās āroundā function will round any number with a decimal point to the nearest whole integer. For example, 3.7 would be rounded to 4, while 7.23 would be rounded to 7. To use the round function:
ā¢ Open any text field in your scenario
ā¢ Select the X1 symbol to access math functions
ā¢ Click on the āroundā function to add it to your selected field
ā¢ Enter the number you want to round between the parentheses
ā¢ Run the module, and the output will include the number rounded to the nearest integer
Find the average of a set of numbersĀ
Make lets you easily calculate the average of several numbers with this simple function. Just enter an array of numbers or values separated by semicolons to calculate the mean. For example, the average of 5, 6, and 7 would be 6.Ā
ā¢ Open any text field in your scenario
ā¢ Select the X1 symbol to access math functions
ā¢ Click on the āaverageā function to add it to your selected field
ā¢ Enter the numbers that you want to use, separated by a semicolon
ā¢ Alternatively, you can enter an array of numbersĀ
ā¢ Run the module to output the average
Generating a random number
Generating a random number can be a useful technique for many automated workflows. To create one in Make, all you have to do is use the prebuilt variable called ārandomā. Hereās how it works:
ā¢ Open any text field in your scenario
ā¢ Select the X1 symbol to access math functions
ā¢ Click on the ārandomā variable to add it to your selected field
ā¢ Run the module to generate a random number between 0 and 1
Generating a number between 0 and 100
In many cases, it will be more appropriate to generate a whole number between 0 and 100 rather than a decimal value between 0 and 1. To do that, you just need to multiply the ārandomā variable by 100 and round the result.Ā
ā¢ Open any text field in your scenario
ā¢ Select the X1 symbol to access math functions
ā¢ Click on the āroundā function to add it to your selected field
ā¢ Add the ārandomā variable between the parentheses of the āroundā function
ā¢ Click on the green multiplication symbol to multiply the ārandomā variable by 100
ā¢ Run the module to check your result
Build more advanced scenarios with math functions
Using Makeās math functions will let you build more sophisticated automations that transform your data and respond effectively to different circumstances. The functions in this post are just a sample of whatās available; try exploring the rest to discover everything you can do with these tools.
If youād like to learn more about workflow automation with tools like Make and Zapier, check out our blog or our YouTube channel. You can also follow XRay on Twitter, Facebook, or LinkedIn.
ā