Stratified Random Selection Tool
  This tool is still a work in progress, but should be functional. Let us know if you get stuck.

Emerging models of public deliberation—such as citizens' juries, citizens' assemblies or deliberative polls—require that the participants be randomly selected. Usually it is desirable for the random selection to be stratified: that is, to be representative of the general population along dimensions such as age, gender, nationality or socio-economic status.

This tool makes it easier to perform such stratified random selection.

Who is providing this tool?

This tool is made available by the newDemocracy Foundation, an independent, non-partisan research and development organisation. We aim to discover, develop, demonstrate, and promote complementary alternatives which will restore trust in public decision making.

Why should I trust it?

To maintain the integrity of a mini-public, it is important when selecting participants

  1. that the selection is genuinely random, and
  2. that personal information about the candidates is kept private.

To this end, this selection tool has the following features.

Open source

The source code for this tool is publicly available and can be found in this GitHub repository.

To ensure you are using the code that is in the GitHub repository, you can access this page via the following direct link on the GitHub Pages domain.

https://newDemocracy-Foundation.github.io/selection-tool/
Runs locally

The selection algorithm will run locally in your browser. The tool will work even if you disconnect from the internet (after initially loading the tool).

The tool does not upload any data (including data that you input, such as candidate information) to the internet.

If you are using any browser extensions, it is possible that you have previously granted them permission to access the data on pages that you visit, including this tool. If privacy is a concern, we suggest you temporarily disable your browser extensions whilst performing the selection to ensure they do not have access to candidate information.

What do I need?

To use the tool, you need two sets of information.
  • A spreadsheet containing demographic information for each of the eligible candidates. To understand the required formatting, please refer to this example Excel spreadsheet, or this CSV file.

  • A spreadsheet containing information about the distribution of demographic factors in the population for which you want your random sample to be representative. To understand the required formatting, please refer to this example Excel spreadsheet, or this CSV file.

Getting Help

If you need help using the tool or understanding if it is right for your situation, please contact Kyle Redman at kyle.redman@newdemocracy.com.au.

If you have any technical questions, bug reports, or suggested improvements, please open an issue in the GitHub repository.

One final note

Be aware that depending on the particular makeup of your pool of candidates, and the specifications of the stratified sample you are trying to obtain, it is possible that the tool may not be able to find a valid sample. If this occurs, the tool will inform you.

This tool makes use of the following JavaScript libraries: jsLPsolver, SheetJS and mathjs. The code is modelled on a similar Python-based selection tool developed by the Sortition Foundation.

First, import your candidate information...

Drag and drop a CSV or Excel file here.

To understand the required format for the candidate information, you can download example candidate information as CSV, Excel.

...then, import your population profile.

Drag and drop a CSV or Excel file here.

To understand the required format for the population profile, you can download example population profile as CSV, Excel.

If you just want to see how the tool works, click here to load the example data.

Selection Algorithm:

Simple

In this algorithm, first a number of panels are generated which satisfy the specified constraints, and then one of those panels is selected at random.

Pros
  • Should work every time.
  • Relatively fast.
Cons
  • Not always fair to individuals because some individuals will be represented in more of the panels than others.
Maximin

In this algorithm, first a number of panels are generated which satisfy the specified constraints, then probabilities are assigned to each of the panels such that the minimum probability than any particular candidate is selected is maximised, and then a panel is selected according to that probability distribution.

Pros
  • Much fairer to individuals than the Simple algorithm.
Cons
  • A bit slower.
  • Might not work. The algorithm can get stuck part way through on larger problems.

Other Settings:

How many people should be selected? The number of people to select. This should be compatible with the numbers you specified in the Population Profile you uploaded in Step 2.
Only 1 per household
When toggled on, the selected panel will include at most 1 person from each household. Households are determined by each candidate's address, as specified by two columns in the Candidate Information spreadsheet you uploaded in Step 2: 'address' and 'postcode'.
Fair to households?
When toggled on, the algorithm will aim to maximise the minimum expected number of candidates selected from each household, rather than the minimum probability that any individual is selected.
Run Selection

Export selected candidates

Download the details of the candidates who were selected, in your preferred format.

CSV
Excel

Export everyone else

Download the candidates who were not selected. This can sometimes be helpful if you need to choose participants for a future event, or if you have someone withdraw their participation and need to select a replacement.

CSV
Excel
Variable Value # Requested # Selected