The Estimator is officially still in its beta phase. The Estimator is designed to enable quick and easy calculations. Look-up tables can be stored and queried within the formula model.
For example, if you create a look-up table with three dimensions, you can set up a clear price matrix to calculate different parameters for a price component.
Structure:
Each Estimator can contain any number of price components.
For each price component, you can decide whether it involves variable costs or fixed costs. Additionally, you can add a description to explain what is being calculated.
For each price component, you can decide whether it involves variable costs or fixed costs. Additionally, you can add a description to explain what is being calculated.
Each price component always contains the same formula fields:
• Formula for internal costs
• Formula for external costs
• Formula for labor costs
• Formula for material costs
The respective costs are displayed separately and clearly in the calculation view.
For each price component, you can define custom variables that will be queried in the input form. These variables can be, for example, floating point numbers, text, or true/false values.
Each variable also has a “technical name”, which represents the path in the input JSON.
This allows you to define the values via the API.
The API URL and your token can be found directly under API access:
https://www.keyline.app/estimations/api/v1/estimations
Each Estimator can be set to PRIVATE
or PUBLIC
.
This setting affects the API
response you receive:
• PRIVATE
: You receive more detailed calculation data.
• PUBLIC
: You only receive the final calculated price.
It is also possible to create a variable that first needs to be calculated.
For example, it might be useful to determine the required material area in square meters as a base calculation before applying surcharges and factors.
Lookup Tables:
Look-up tables are simple Excel lists that can have multiple dimensions.
To keep complexity manageable, it is recommended to work with a maximum of three dimensions (columns, rows, and individual sheets).
This is part of the basic configuration when creating a LookupTable.
At the bottom, you will find an example of a Lookup Table.
Once you have successfully uploaded the table, you can:
Search for values directly, Download the entire list or Edit the table.
In a price component, you could define the formula like this:
(LOOKUP("Your-LookUp-Table_ID", circulation, number_of_pages, mashine_typ)*100)*circulation
If a default value should be returned when no matching value is found in the table, you can use:
(LOOKUP_WITH_DEFAULT("YOUR-LookUp-Table_ID", 1000, circulation, number_of_pages, Machine_type) * 100) * circulation
In this case, 1000 will be returned if no value is found for the given parameters.
Instead of 1000, a more complex calculation or another formula can be used.
Available Functions & Variables:
You can use various functions and operators, including:
Logical Operators & Conditions:
if
, not
, min
, max
, sum
, and round
Mathematical Functions:
<
, >
, <=
, >=
, <>
, !=
, =
,
IF
, AND
, OR
, XOR
, NOT
, SWITCH, MIN
, MAX
, SUM
, AVG
, COUNT
, ROUND
, ROUNDDOWN
, ROUNDUP
, ABS
, INTERCEPT
Examples:
Finding Minimum or Maximum Values:
Max(10,9,8,7)
=> 10
Min(10,9,8,7)
=> 7
Rounding Examples:
Round(8.3)
=> 8
Round(8.5463,2)
=> 8.55
(der zweite Wert bestimmt die Dezimalstelle, auf die gerundet werden soll
Rounddown(55.55)
=> 55
Roundup(55.55)
=> 56
Round(Seitenanzahl/2)*2
=> Ensures the result is always an even number
Range Switch Function:
RANGESWITCH(number_of_pages,1,64,64,65,128,128,129,240,240,241,300,300,11111)
If PageCount is:
• Between 1 and 64 → Returns 64
• Between 65 and 128 → Returns 128, etc.
Switch Function (Direct Mapping):
SWITCH(PageCount,8,80,16,160,200,2000,11111)
If PageCount is 8, it returns 80.
If PageCount is 200, it returns 2000.
If no matching value exists, it returns 11111.
Alternatively, you can of course also use a nested if/then function:
IF(placeholder_with_twenty<=5, 1, IF(placeholder_with_twenty<=10, 2, IF(placeholder_with_twenty<=15, 3, IF(placeholder_with_twenty<=20, 4, 5))))
=> 4
placeholder_with_twenty
is used as a variable with the default value 20. This allows formulas to be tested very well and clearly.
or a simple:
if(128>64,1,0)
=> 1
or you work with AND
:
IF(AND(328>64, 328<=265), 1, 2)
=> 2
The input is 328 - if the input is bigger than 64
AND
smaller than 265
, you get 2
.
Or with a boolean
with true/false
:
if(reprint= true and tool_cost="high",4,5)
=> 4
Formula Comments:
Formulas can also include comments to explain their purpose.
/*
This is a multi-line or single-line comment
*/
SWITCH(PageCount,8,80,16,160,/* Additional Info */ 200,2000,11111)
Comments can also be placed inside formulas.
This is helpful if you want to verify certain values later or are unsure about a calculation.
Questions?
If you have any questions about the Estimator, feel free to reach out.
As mentioned, the Estimator is still in beta, and many new features will be added soon, such as auto-completion and more.
At the bottom, you’ll also find an example Excel file for a three-dimensional Lookup Table.