## Introduction

This article describes how to compute shares from numeric data at the case (eg respondent) level. The table below shows the average number of hours spent during the week doing each of the activities:

And below is the table of the new variable created where the case-level share has been computed.

## Requirements

- A Displayr document containing numeric data.

## Method

- Select the numeric variable in the
**Data Sets**tree that you would like to compute the case-level shares. - Either hover over any variable in your
**Data Sets**tree**> Plus (+) > Insert Variable(s) > Ready-Made New Variable(s) > Case-Level Shares**or else from the toolbar menu, select**Anything > Data > Variables > New > Ready-Made New Variable(s) > Case-Level Shares**. - OPTIONAL: A simpler and often better method for computing shares is to use the share statistics available in the
**object inspector**under**Inputs > STATISTICS > Cells**. Generally, the shares computed when showing the**Average**of the variables created using this QScript will differ from those obtained if selecting one of the shares from**Inputs > STATISTICS > Cell**, as the**Average**will show the average of the shares computed at the respondent (case level), whereas the shares computed using**Inputs > STATISTICS > Cell**is created by summing up the data for each case and thus give greater weight to cases with larger values.

## See Also

How to Show Average Rank in a Table

## Comments

0 comments

Article is closed for comments.