# Transform

### How this function differs from "Compact to..." and how to use it

Protobi allows you to calculate a value for a group based on its children elements by defining a Transform.

"Transform..." is different from "Compact to..." in that it calculates a new aggregate value for the parent group rather than showing summary statistics for each child element.

## Example

Your survey might have a question where you ask respondents to enter multiple percentages that sum to 100. Each individual percentage is its own question and has its own distribution. The results might appear as follows:

### Transform to sum

In reference to the example above, you may want to make sure that the percentages really do sum to 100. You can calculate that sum within Protobi. Press the square edit icon for the group and select "Transform..."

This will bring a dialog showing a number of options to combine the element values into one aggregate value:

Below is the distribution for the resulting sum.

Surprise! Not all of the percentages actually sum to 100. Some are below and many way above. Better talk to the survey programmer...

When you select a Transform, by default Protobi will hide the distributions for the child elements. To show those distributions, press the square edit icon and select "Expand/collapse."

To return to the original state, bring up the "Transform..." dialog and select "None."

## See related

There are more complicated transform options that are not covered in this tutorial.

For an example of:

- Transform to compact (squash), see Transform to compact
- Transform to condense (squish), see Condense text verbatims