Powerful interactive ‘dot’ visualisation, good for exploring survey results and more

Updated 19 days ago to v4.0.0 by Flourish team

How to use this template

This template is ideal for visualising survey responses and other data where each row represents a discrete entity such as a person. It lets you animate dots into different views, including groups, bars, and – for geographic data – a world map. It also allows you to compare different metrics in a grid view.

Data requirements

The survey template is ideal for datasets up to around 10,000 rows. Larger datasets will work, but perform more slowly.

You'll need a CSV or Excel file with a row for each person or entity that you want to visualise.

In the case of survey data, your CSV file should have:

– a row for each person who took the survey

  • a column for each question in the survey or other piece of information about the respondent

Getting started

First, from your projects page, create a new Survey visualisation. Open the Data view, go to the “Data” sheet and import your data to overwrite the current sheet. Then, on the right, update the column settings:

  • Set “Categorical columns” to point to any columns with categorical answers, i.e. text like "male"/"female" or "0-99"/"100-999"/"1000-9990". Type in the column numbers - e.g. A-C. These columns will appear in in the “Group by”, “Shade by” and “Compare” dropdown in the visualisation.
  • Set “Continuous columns” to point to any columns with continuous answers, i.e. raw numbers, such as income or weight. These columns will appear in the “Size by” dropdown in the visualisation.

If you switch back to the Preview view, you should now see your data in the survey.

Change the text displayed

It's quite common that you want to change text shown in the visualisation - for example, you might have y and n as answers in your raw data, but want this to be displayed as yes or no in your visualisation.

To avoid editing the raw data (which may make it harder to update later), you can use the “Label overrides” sheet. Simply type the values you want to change (e.g. y) in the first column and the values you want to show (e.g. yes) in the second column. The visualisation should automatically update to show the new text.

Change the ordering of groups

It's also quite common that you want to change the order of answers, which by default will display alphabetically. For example, you might prefer to show groups for Yes, No, and Answer not supplied in that order.

To do this, go to the “Natural order” data sheet, and fill in the heading of column A with the column name of the relevant question in the “Data” sheet. Underneath, type or paste in the answer values in the order that you'd like them displayed. Then, in the column settings panel, update “Order of answers” to point at column A.

You can repeat this for as many columns as necessary.

Customise the popups

In the data bindings panel, find “Metadata” and add any columns that you want to include in popups. Then, in the settings panel, ensure “Show popups” is checked, and edit “Popup contents” to include the columns, with column names in {{brackets}}.

The “Popup contents” is HTML, so you can include formatting, e.g. <strong>Name:</strong> {{Name}}, or even images if you include image URL in your data sheet.

If this isn't working, check you're using the exact column names and that you haven't included spaces inside the brackets - so {{Name}} not {{ Name }}.

Let users filter the data

You can allow users to filter your survey results within the visualisation - e.g. by year or another attribute.

To do this, in the data bindings panel, update the “Slider or menu” binding to point at the column you want to filter by.

Then, in the settings panel, choose “Control style” to specify the type of filter control you want - a button group, dropdown, or slider.

Grouped question

Survey data often includes grouped questions – i.e. those in the form "What food do you like (pick up to three)". In this model, the data sheet would typically include a column for each possible answer with a yes or no answer. The template allows you to group these questions together to enable you to compare the frequency of the positive answers.

When grouping by such a question, the number of dots may increase, because each survey respondent may appear multiple times – one for each positive answer. Because of this it's not possible to shade by a grouped question.

To create a grouped question, use the “Answer Groups” sheet. Put in the question you want to create in the first column, the column header for each sub-question in the next column, the display name for the group in the following column, and finally the way a positive answer is seen – e.g. “y” or “1”.

Display your data on a map

If you have country names in your data, you can display the data on a world map without doing much extra work. Just ensure that the “Geographic columns” binding points at the column with country names in it, and that your country names match the “Countries” sheet.

If your data has other geographic locations, such as city names, you'll need to do a bit more work! First, ensure that the “Geographic columns” binding points at the column with locations in it. Then replace the “Countries” sheet with your geographic locations - you'll need latitude, longitude and name columns.

To change the default position displayed on the map, you'll need to create a Flourish story. Inside the story, click the map view, then zoom to the position you want to display: the slide will save the position. Publish the story to share it with your users.

API information

Explains to developers how to use this template with the Flourish Live API.

template: @flourish/survey

version: 4


dot_fill color

Default colour. The colour of the dots if nothing is selected on the “Shade by” menu

dot_opacity number


Max: 1

colors colors

Colour when shading. The colours to use when shading by the answer to a question

avoid_neat_groups boolean

Messier groups. Fractionally randomises the size of the dots to avoid overly “neat” grid-style groups. Ignored when “Size by” is in use.

dot_shape string


Allowed values:

  • circle (Circle)
  • square (Square)
  • polygon (Polygon)

dot_sides number


Min: 3

Max: 16

dot_label string

Default label or emoji. A label or emoji to show on each dot. Overriden by any label specified using the Label column setting.

dot_label_color color


dot_label_bold boolean

Bold. The minimum text size for dot labels. Below this level they will not render.

dot_label_min number

Min size to display. The minimum text size in pixels for dot labels. Below this level they will not render.

dot_label_auto_size boolean

Sizing mode. The minimum text size in pixels for dot labels. Below this level they will not render.

Allowed values:

  • true (Auto)
  • false (Fixed)

dot_label_fixed number

Size in %. Specifies font size across the graphic as % of dot height.

dot_label_scale number

Scale. Scales the labels up or down from their default size


all_group_label string

Name for "all" group.

include_grouped_questions_on_shade_menu boolean

Include grouped questions on shading menu. Should grouped questions be included on the shading menu?

order_groups_by_size boolean

Order groups by size.

exclusions string

Exclude groups with the following names. Case-sensitive comma-separated list

exclude_blanks boolean

Exclude groups with blank names.

Group labels

label_circular boolean

Label postion.

Allowed values:

  • false (Above group)
  • true (Around group)

label_color color

Text colour.

label_min_font_size number

Min font size. In pixels; the actual font size in any view is set automatically between the min and max

label_max_font_size number

Max font size. In pixels; the actual font size in any view is set automatically between the min and max

label_shadow_size number

Size. As percent of font size

Max: 100

label_shadow_custom boolean


Allowed values:

  • false (Auto)
  • true (Custom)

label_shadow_color color


label_group_count boolean

Show number of dots in group. Adds the number in brackets after the main label; ignored in chart, map and compare modes

label_group_percent boolean

Show group size as % of visible dots. Adds to the labels group size as a in brackets after the main label; ignored in chart, map and compare modes, and when showing a grouped question

label_group_percent_decimals number

Decimal places on percentage labels.

always_show_x_label boolean

Show X label when not comparing. Show the groups label at the bottom when not comparing two metrics

show_xy_axis_labels_when_comparing boolean

Show X/Y labels when comparing. Show groups labels on both axes when comparing two metrics

compare_y_axis_width number

Y axis width.

compare_x_axis_height number

X axis height.

Background image

background_image url

Image URL. Must be a secure URL, i.e. one that starts “https://”

background_image_mode string


Allowed values:

  • cover (Fill)
  • contain (Fit)
  • stretch (Stretch)
  • tile (Tile)


map_max_group_size number

Max group size in map view.

Min: 1

map_opacity_map_mode number

Map opacity (in map mode).

Max: 1

map_opacity_non_map_mode number

Map opacity (in other modes).

Max: 1

max_map_strech number

Max map strech (%).


select_group_text string

Text above "Group by" dropdown.

select_map_text string

Text above "Group location" dropdown.

select_color_text string

Text above "Shade by" dropdown.

select_size_text string

Text above "Size by" dropdown.

select_compare_text string

Text above "Compare" dropdown.


show_popups boolean

Show popups. Whether or not to show info popups when hovering over the dots

Popup contents. Can include any HTML with column headers in double curly brackets, such as {{Gender}}


panel_background_color color


panel_background_opacity number


Max: 1

panel_text_color color

Text color.

panel_text_size number

Text size.

panel_icon_color string

Icon color.

Allowed values:

  • light (Light)
  • dark (Dark)

panel_width number

Panel width. Width of the controls panels on wide screens, ignored on mobile

panel_overlay boolean

Overlay panel over graphic.

column_filter_style string

Control style.

Allowed values:

  • slider (Slider)
  • grouped-buttons (Button group)
  • dropdown (Dropdown)

column_filter_show_play boolean

Show play button next to slider.

column_filter_show_all boolean

Include "All" in slider/menu.

column_filter_show_all_label string

Custom label for All.


legend_mode string

When to show legend. Legend is only available when shading by a column

Allowed values:

  • auto (Auto)
  • always (Always)
  • never (Never)

legend_text_color color


legend_hide_space boolean

Remove space when empty. Turn off to avoid the legend taking up space when empty. Leave on to avoid the graphic jumping up and down a little when the legend is revealed or hidden.

legend_hide_label boolean

Remove legend title.


zoom_on_double_click boolean

Zoom on double click.

zoom_on_mousewheel boolean

Zoom on pinch/mousewheel.


transition_duration number

Duration. Time in milliseconds of each dot's animation

transition_stagger number

Stagger. The spread of time over which the dots start animating


layout.body_font font


layout.max_width number

Maximum width. Leave blank to stretch to container width

Min: 50

layout.background_color color


layout.margin number


layout.layout_order string

Layout order.

Allowed values:

  • stack-default (data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAdCAYAAAHZdKxuAAAAAXNSR0IArs4c6QAAANhJREFUSA3tVNEOwiAM7Iy/p2/wkTz6g5gjOVZZEepcjMmWLBTau95ugIh6lpzzLcb4wNpFJaRk9MIahxAyXmD7mC7BC2RlFbliQjFMpJTujOdGs/ECwRoP3rlKoEzNJlz3+CwutK0NLRVt2QhjggA9n2IGEKANMxmt0VVsEfxgzfX7zL3ZiqbXLjcKc8vEORk5/75mMB/7u11uuIpdbtDCc5R3l/s+e+pmHt1foza7Nv6IXOeHiqGk9zWtSk1cN2cPrItnYjZzHZEZYtacxHTiuANSO/xN8AS4uW8Rw1Gu2AAAAABJRU5ErkJggg==)
  • stack-2 (data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAdCAYAAAHZdKxuAAAAAXNSR0IArs4c6QAAAMpJREFUSA3tVMsKwyAQNKW/l970Iz32Bw0jjKTrSLUY0oOBsO5rnOwYnTs9W0ppDyG8EcsOkw8uauu9T3jR2+75yJxBnnC4JxMxxlezg0V9VsJsIGz75TfKdlkpg3aPcT8TsPNRMJjZEIf5xaAAahUyE+RtfcZvtFLoFh95aFXxH4hCWpUoTCg7fxqUfB4yEcl/CJlNy5qbfuZA8m8CwJ77q2djSj50lnuAWbOAOQlXxCuRHxcUje2XzfgrYzBpHUXLkmxh181SpnEAB4Vg0DSGhHsAAAAASUVORK5CYII=)
  • stack-3 (data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAdCAYAAAHZdKxuAAAAAXNSR0IArs4c6QAAANFJREFUSA3tVEEOwyAMo9O+193gkRz3QSZHMmNRUkGp1guVqkCIHZMAITTfVkrZU0pv+B7NQpCV1vEdxxgLfmB9jEvwBBNzkjXn/HIRDOqzJs0GwS1eEmonAn52RITJaUYScd5KLl0fTQf58HVpIFlXMDPNBVMf2TDXPq7dZM2eelrMQ6uDucG50mlWzG/ooCWDvqENXldn1pcyhpgJWjYcPe5z5ZFrAgoe2LN0f2v1ZYq5UyofuiME99hFXKtUm1c9aoBmeEeRjVIQma6XpVblAwnpZjN/VjqsAAAAAElFTkSuQmCC)
  • stack-4 (data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABYAAAAdCAYAAAHZdKxuAAAAAXNSR0IArs4c6QAAANtJREFUSA3tVNEOwjAI3Iy/p2/tR/bRH6zekmuA1glO45bYZAHKcdDCOk1izbXWC+0zlJzzDVJ5sNGW9qSUKj4QKY8yWvBDUWnoKKVcTzS2yWHiIfeMwm2yIbLbRL3DRJYubi+0bAPCkcvapO3AdFgZvuDuyJZR2i4wSpBBP9ZD7RsOLQ9gD/Y5ZmaA3EEHWY6r3SEwrzDEHLpnlvOXa4/7xttZfhNwyPdKcqLPaz6JlXpr9bNgCfbobw2ch5iY0CQzyCOPR9ya5zleBPNy3LxknAbiv1YxExxH3gEqBW7I4zw3PQAAAABJRU5ErkJggg==)

layout.space_between_sections string

Space between sections.

Allowed values:

  • 0 (▁)
  • 0.5 (▃)
  • 1 (▄)
  • custom (...)

layout.space_between_sections_custom number


Max: 100


layout.header_align string


Allowed values:

  • left (fa-align-left)
  • center (fa-align-center)
  • right (fa-align-right)

layout.title string

layout.title_styling boolean

Change title styles.

layout.title_size string


Allowed values:

  • 1.4 (ᴀ)
  • 1.6 (A)
  • 2 (fa-font)
  • custom (...)

layout.title_size_custom number

Custom. Specify a custom responsive font size. Best results will be with values between 1.2 and 3

layout.title_weight string


Allowed values:

  • bold (Bold)
  • normal (Regular)

layout.title_color color


layout.title_line_height number

Line height.

Max: 3

layout.subtitle string

layout.subtitle_styling boolean

Change subtitle styles.

layout.subtitle_size string


Allowed values:

  • 1.4 (ᴀ)
  • 1.6 (A)
  • 2 (fa-font)
  • custom (...)

layout.subtitle_size_custom number

Custom. Specify a custom responsive font size. Best results will be with values between 1.2 and 3

layout.subtitle_weight string


Allowed values:

  • bold (Bold)
  • normal (Regular)

layout.subtitle_color color


layout.subtitle_line_height number

Line height.

Max: 3

layout.subtitle_space_above string

Space above.

Allowed values:

  • 0 (▁)
  • 0.5 (▃)
  • 1 (▄)
  • custom (...)

layout.subtitle_space_above_custom number


Max: 100

layout.text string

layout.text_styling boolean

Change text styles.

layout.text_size string


Allowed values:

  • 1.2 (ᴀ)
  • 1.4 (A)
  • 1.6 (fa-font)
  • custom (...)

layout.text_size_custom number

Custom. Specify a custom responsive font size. Best results will be with values between 1.2 and 3

layout.text_weight string


Allowed values:

  • bold (Bold)
  • normal (Regular)

layout.text_color color


layout.text_line_height number

Line height.

Max: 3

layout.text_space_above string

Space above.

Allowed values:

  • 0 (▁)
  • 0.5 (▃)
  • 1 (▄)
  • custom (...)

layout.text_space_above_custom number


Max: 100


layout.source_name string

Source name.

layout.source_url string

Source url.

layout.multiple_sources boolean

Multiple sources.

layout.source_name_2 string

Source name.

layout.source_url_2 string

Source url.

layout.source_name_3 string

Source name.

layout.source_url_3 string

Source url.

layout.source_label string

Source label.

layout.note string


layout.size number


layout.color color


layout.footer_align string


Allowed values:

  • left (fa-align-left)
  • center (fa-align-center)
  • right (fa-align-right)
  • justify (fa-align-justify)

layout.logo_url url



layout.logo_height number


layout.logo_margin number


layout.logo_order string


Allowed values:

  • left (Left)
  • right (Right)

layout.footer_align_vertical string

V. align.

Allowed values:

  • flex-start (Top)
  • center (Center)
  • flex-end (Bottom)