> For the complete documentation index, see [llms.txt](https://help.imotions.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.imotions.com/lab/exports/r-processed-exports/export-r-processed-respondent-statistics.md).

# Export: R Processed Respondent Statistics

Export respondent counts and age statistics by group and gender from an iMotions Lab analysis with the Respondent Statistics export.

The R-notebook is called: **Respondent Statistics**. It produces file exports for respondents statistics under the created analysis.

## 1. How to Specify Information of Respondents

You can specify Name, Gender, Age, Group of the respondent when you create a respondent in iMotions. These four types of information will be able to be exported later.

![The form for adding a respondent](https://286068319-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNLNBWkNpljDaAj5rQtNa%2Fuploads%2Fgit-blob-2f5171429d3724ca4129131d8b1f93e0db2f697e%2Flab_respondents_add-respondent-form.png?alt=media)

You can also update respondent information even after you have collected data for that respondent: click on your study -> click on the respondent name -> click on "RESPONDENT DETAILS" -> then "Update" once you finish the update.

![The Respondent Details tab of a selected respondent](https://286068319-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNLNBWkNpljDaAj5rQtNa%2Fuploads%2Fgit-blob-e437b9143d7ce08014f57c8e814675aaf82fbb50%2Flab_respondents_recorded-data.png?alt=media)

## 2. How to Export in iMotions Desktop

To export respondents statistics under your created analysis, the following steps need to be followed:

1\. Create a new analysis to include the respondents for which you wish to export the statistics:

![The Add Analysis button on a study in the Library](https://286068319-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNLNBWkNpljDaAj5rQtNa%2Fuploads%2Fgit-blob-0b352d688758cd75a0a20712355835132fb525d1%2Flab_library_add-analysis-button.png?alt=media)

2\. Advance through the steps "Segmentation settings" and "Segmentation criteria" with your preferred selections of respondents to be included in your analysis. Tips: You can right click your mouse under RESPONDENTS panel to *Select all* or *Deselect all*.

![The Segmentation criteria page of a new analysis with the right-click menu of the Respondents list open](https://286068319-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNLNBWkNpljDaAj5rQtNa%2Fuploads%2Fgit-blob-27051a3e8e2a56862b1a37db27059889fb1a2548%2Flab_analysis_new-analysis_respondents-menu.png?alt=media)

3\. After clicking Next, you reach the step "Signal processing". Please note that you *don't* need to add any notebook in this step in order to export respondent statistics, it is built in iMotions already. However, you are free to add any other notebook for your other analysis purposes. The same applies to the next step: "Select Stimuli". However, in this step, you have to select at least one stimulus, otherwise, iMotions will throw a warning saying: At least one stimulus needs to be selected for analysis.

4\. You can access the exported file under your created analysis by (1) clicking on the 'Export' button, (2) under 'R PROCESSING', you can (3) click on 'Respondent Statistics Export', and then (4) click on 'Export' button to generate the file in .txt format.

![The R Processing tab of an analysis's Export panel](https://286068319-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNLNBWkNpljDaAj5rQtNa%2Fuploads%2Fgit-blob-ca5cbaa728f6f370790bf206eb1e4f63acfe6256%2Flab_analysis_export_r-processing.png?alt=media)

## 3. Outputs: Exported file

The generated file is composed of two parts: summary statistics of all the exported respondents and information of each individual respondent. All the information is based on what has been specified in iMotions. See section 1, How to Specify Information of Respondents.

For the summary statistics part: count number, average age, median age, standard deviation age have been calculated based on grouping variables: **Group** and **Gender**.

For individual respondent information, Name, Age, Gender and Group will be given.

Please see an example export file in the attachment.

![export\_file.png](https://286068319-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FNLNBWkNpljDaAj5rQtNa%2Fuploads%2Fgit-blob-2d3ddbc2d63611e82c1db2492827fd3fdccf223b%2F55a4b38a0b_export_file.png?alt=media)


---

# 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://help.imotions.com/lab/exports/r-processed-exports/export-r-processed-respondent-statistics.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.
