> For the complete documentation index, see [llms.txt](https://community-test.logicnets.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://community-test.logicnets.com/release-9/platform-documentation/process-node-parts/group-calculations.md).

# Group Calculations

## Description

The *group calculations* part allows you to assess the number and weight of a user's responses to a set of similar questions. These questions are typically written/structured as "Indicate your preferences for each of the following items on the scale High, Medium, Low".

Regardless of the number of questions in this construction, group calculations will report the numbers and the questions selected for any given value choice; for example, it will show all items selected as "High". To get the full analysis, add one group calculation part for each answer option.

**Node Type:** This part is available in a process step.

**Used With:** This part is used with the Assessment Framework and Starter Application Framework.

## Example

Click [here](/release-9/example-gallery/example-projects-for-parts/group-calculations-example-project.md) to download an example project using the *group calculations* part.

## Tips and Tricks

### Using the Part

Make sure that the data object for each question included in the group includes the common group name followed by the variable in which to store the specific answer. For instance, the full data objects for a set of questions asking about the user's interest in various sports would be:

* interest\_level.football
* interest\_level.tennis
* interest\_level.baseball

Make sure that each radio list has the same set of answer options, e.g. high, medium, low, no interest.

Note that this part does NOT work with collections where the object in the data structure would be interest\_level\[1].football or the value is shown in the DATA tab as outlined below. (See the part [count\_items\_in\_collection](/release-9/platform-documentation/process-node-parts/count-sum-items-in-collection.md) for use with collection variables)

```
[ ] interest_level            [ ] signifies collection while { } signifies group/container
#1 = "football"                #1 signifies first position in the collection
etc.
```

### Designer Tips

Once you have decided on the answer categories (e.g. High, Medium, Low), create the first radio list. Then, instead of starting with another blank node, copy the first node and change the data object.

Typically, you will not need to repeat a caption for each question in the group. Leave caption blank and use a TITLE form part node to introduce the questions at the start of the section, as in this medical example:

![](https://2802811211-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FdFhfexCjZ5JMhwGzzywq%2Fuploads%2Fgit-blob-f7656a4f836287189a9833fdf4fd5f791d7c64a8%2F55a793a2-e247-461a-99e2-ec2b5aed6073.jpg?alt=media)

### Show the Resulting Collection

The *group calculations* part outputs a list of the data objects that match a chosen value. Note that this could be used in downstream processing; for instance, asking follow-up questions for each topic.

Your application may simply need to echo back the user's choices on the right side of the Assessment Framework; for instance, as a bulleted list or as text (A, B, and C). This can be achieved simply by using the report-item part to show the *Group values Data Object.*

When the objects for each question are multi-word (e.g. *ice hockey*) you must set them up without spaces in the data object field (i.e *ice\*\*\_\*\*hockey*). This is also how the system stores the value in the list as well. To make these more "human-readable" as answers, consider using a sequence of process steps to convert them:

1. Use *convert collection to text* or *format variable* part. The output result would be "american\_football, ice\_hockey, college\_basketball"
2. Use *find and replace text*. The output result would be "american football, ice hockey, college basketball".

Raw output and processed output from the Example Project is shown here:

![](https://2802811211-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FdFhfexCjZ5JMhwGzzywq%2Fuploads%2Fgit-blob-618a513500ee7d45a77dd15ed21fc074cfc239f6%2F6f9ddf7d-13e7-465c-b7c3-0596d48f0ab7.jpg?alt=media)

## Setting the Parameters

### Basic Functions

The table below contains the fields you must fill out for the report-item to work.

| Field Name               | Description/Use                                                                                                                                                                                                                                                                                                                        | Type/Options |
| ------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------ |
| Group                    | This is where you enter the group name used in each radio list that makes up the group, e.g. "interest\_level".                                                                                                                                                                                                                        | Text         |
| Value                    | This is where you specify one of the radio list answer options, e.g. "high".                                                                                                                                                                                                                                                           | Text         |
| Result Data Object       | <p>This container stores several pieces of analysis of the group related to the \[value] chosen:<br>- number of answered questions in the group<br>- group\_count = number of times the specific answer value was chosen<br>- items {not used]<br>- weight = sum of weights associated with the chosen answer across the questions</p> | Container    |
| Group values Data Object | This is where you povide the name of the collection in which the system will store a list of the specific data objects that were answered as \[value].                                                                                                                                                                                 | Collection   |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://community-test.logicnets.com/release-9/platform-documentation/process-node-parts/group-calculations.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
