File:Opinion polling for the next Thuringian state election.svg

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

Original file (SVG file, nominally 844 × 559 pixels, file size: 79 KB)

Captions

Captions

Graph of opinion poll results for the next state election in Thuringia, Germany, due in September 2021.

Summary

[edit]
Description
English: Each dot represents an individual opinion poll result. Trendlines are local regressions, with bandwidth set to 0.5.

Parties:

 AfD
 CDU
 SPD
 FDP
How to update this graph
  • Open the online Vega editor
  • Click on the dropdown menu in the top-left corner and select "Vega-Lite"
  • Copy the syntax in the box below, and paste it into the editing area
Graph syntax
{
  "$schema": "https://vega.github.io/schema/vega-lite/v5.json",
  "description": "Opinion polling for the Next Thuringian state election",
  "width": 800,
  "height": 500,
  "data": {
    "values": [
      {
        "Date": "2022-03-01",
        "LINKE": 25,
        "AFD": 23,
        "CDU": 19,
        "SPD": 16,
        "GRUNE": 6,
        "FDP": 6
      },
      {
        "Date": "2022-02-22",
        "LINKE": 23,
        "AFD": 24,
        "CDU": 19,
        "SPD": 15,
        "GRUNE": 5,
        "FDP": 7
      },
      {
        "Date": "2021-11-30",
        "LINKE": 24,
        "AFD": 23,
        "CDU": 15,
        "SPD": 18,
        "GRUNE": 7,
        "FDP": 7
      },
      {
        "Date": "2021-10-04",
        "LINKE": 20,
        "AFD": 23,
        "CDU": 15,
        "SPD": 21,
        "GRUNE": 7,
        "FDP": 8
      },
      {
        "Date": "2021-07-23",
        "LINKE": 27,
        "AFD": 22,
        "CDU": 21,
        "SPD": 11,
        "GRUNE": 6,
        "FDP": 6
      },
      {
        "Date": "2021-07-15",
        "LINKE": 27,
        "AFD": 22,
        "CDU": 21,
        "SPD": 9,
        "GRUNE": 7,
        "FDP": 8
      },
      {
        "Date": "2021-06-14",
        "LINKE": 26,
        "AFD": 23,
        "CDU": 22,
        "SPD": 9,
        "GRUNE": 6,
        "FDP": 7
      },
      {
        "Date": "2021-03-16",
        "LINKE": 30,
        "AFD": 23,
        "CDU": 19,
        "SPD": 9,
        "GRUNE": 8,
        "FDP": 6
      },
      {
        "Date": "2021-03-01",
        "LINKE": 29,
        "AFD": 23,
        "CDU": 22,
        "SPD": 10,
        "GRUNE": 5,
        "FDP": 6
      },
      {
        "Date": "2021-02-02",
        "LINKE": 31,
        "AFD": 23,
        "CDU": 22,
        "SPD": 7,
        "GRUNE": 8,
        "FDP": 6
      },
      {
        "Date": "2020-11-05",
        "LINKE": 33,
        "AFD": 22,
        "CDU": 22,
        "SPD": 9,
        "GRUNE": 6,
        "FDP": 5
      },
      {
        "Date": "2020-10-12",
        "LINKE": 33,
        "AFD": 22,
        "CDU": 22,
        "SPD": 8,
        "GRUNE": 7,
        "FDP": 4
      },
      {
        "Date": "2020-09-02",
        "LINKE": 33,
        "AFD": 22,
        "CDU": 22,
        "SPD": 9,
        "GRUNE": 5,
        "FDP": 4
      },
      {
        "Date": "2020-08-04",
        "LINKE": 32,
        "AFD": 20,
        "CDU": 24,
        "SPD": 10,
        "GRUNE": 6,
        "FDP": 4
      },
      {
        "Date": "2020-06-22",
        "LINKE": 35,
        "AFD": 22,
        "CDU": 22,
        "SPD": 8,
        "GRUNE": 6,
        "FDP": 3
      },
      {
        "Date": "2020-05-19",
        "LINKE": 34,
        "AFD": 22,
        "CDU": 21,
        "SPD": 8,
        "GRUNE": 7,
        "FDP": 5
      },
      {
        "Date": "2020-03-31",
        "LINKE": 37,
        "AFD": 23,
        "CDU": 18,
        "SPD": 7,
        "GRUNE": 7,
        "FDP": 4
      },
      {
        "Date": "2020-03-09",
        "LINKE": 38,
        "AFD": 25,
        "CDU": 15,
        "SPD": 8,
        "GRUNE": 6,
        "FDP": 4
      },
      {
        "Date": "2020-02-13",
        "LINKE": 40,
        "AFD": 25,
        "CDU": 14,
        "SPD": 7,
        "GRUNE": 6,
        "FDP": 4
      },
      {
        "Date": "2020-02-10",
        "LINKE": 39,
        "AFD": 24,
        "CDU": 13,
        "SPD": 10,
        "GRUNE": 5,
        "FDP": 4
      },
      {
        "Date": "2020-02-06",
        "LINKE": 37,
        "AFD": 24,
        "CDU": 12,
        "SPD": 9,
        "GRUNE": 7,
        "FDP": 4
      },
      {
        "Date": "2020-02-06",
        "LINKE": 34,
        "AFD": 23,
        "CDU": 19,
        "SPD": 6,
        "GRUNE": 6,
        "FDP": 7
      },
      {
        "Date": "2020-01-25",
        "LINKE": 32,
        "AFD": 24,
        "CDU": 19,
        "SPD": 8,
        "GRUNE": 6,
        "FDP": 6
      },
      {
        "Date": "2019-10-27",
        "PreLINKE": 31,
        "PreAFD": 23.4,
        "PreCDU": 21.7,
        "PreSPD": 8.2,
        "PreGRUNE": 5.2,
        "PreFDP": 5
      }
    ]
  },
  "encoding": {
    "x": {
      "field": "Date",
      "type": "temporal",
      "scale": {"domain": ["2019-10-27", "2022-12-31"]},
      "axis": {
        "title": "Date",
        "tickCount": 12,
        "labelExpr": "[timeFormat(datum.value, '%b'), timeFormat(datum.value, '%m') == '01' ? timeFormat(datum.value, '%Y') : '']",
        "gridWidth": {
          "condition": {
            "test": {"field": "value", "timeUnit": "month", "equal": 1},
            "value": 1
          },
          "value": 0.5
        },
        "tickWidth": {
          "condition": {
            "test": {"field": "value", "timeUnit": "month", "equal": 1},
            "value": 1
          },
          "value": 0.5
        }
      }
    },
    "y": {
      "type": "quantitative",
      "scale": {"domain": ["0", "50"]},
      "axis": {"title": "%Support", "tickCount": 10}
    }
  },
  "layer": [
    {
      "mark": {
        "type": "point",
        "color": "#eb001f",
        "fill": "#eb001f",
        "size": 10
      },
      "encoding": {"y": {"field": "SPD", "title": "SPD"}}
    },
    {
      "mark": {
        "type": "point",
        "color": "#000000",
        "fill": "#000000",
        "size": 10
      },
      "encoding": {"y": {"field": "CDU", "title": "CDU"}}
    },
    {
      "mark": {
        "type": "point",
        "color": "#64a12d",
        "fill": "#64a12d",
        "size": 10
      },
      "encoding": {"y": {"field": "GRUNE", "title": "GRUNE"}}
    },
    {
      "mark": {
        "type": "point",
        "color": "#be3075",
        "fill": "#be3075",
        "size": 10
      },
      "encoding": {"y": {"field": "LINKE", "title": "LINKE"}}
    },
    {
      "mark": {
        "type": "point",
        "color": "#ffed00",
        "fill": "#ffed00",
        "size": 10
      },
      "encoding": {"y": {"field": "FDP", "title": "FDP"}}
    },
    {
      "mark": {
        "type": "point",
        "color": "#009ee0",
        "fill": "#009ee0",
        "size": 10
      },
      "encoding": {"y": {"field": "AFD", "title": "AFD"}}
    },
    {
      "mark": {"type": "square", "fill": "#eb001f", "size": 30, "opacity": 1},
      "encoding": {"y": {"field": "PreSPD", "title": "PreSPD"}}
    },
    {
      "mark": {"type": "square", "fill": "#000000", "size": 30, "opacity": 1},
      "encoding": {"y": {"field": "PreCDU", "title": "PreCDU"}}
    },
    {
      "mark": {"type": "square", "fill": "#64a12d", "size": 30, "opacity": 1},
      "encoding": {"y": {"field": "PreGRUNE", "title": "PreGRUNE"}}
    },
    {
      "mark": {"type": "square", "fill": "#be3075", "size": 30, "opacity": 1},
      "encoding": {"y": {"field": "PreLINKE", "title": "PreLINKE"}}
    },
    {
      "mark": {"type": "square", "fill": "#ffed00", "size": 30, "opacity": 1},
      "encoding": {"y": {"field": "PreFDP", "title": "PreFDP"}}
    },
    {
      "mark": {"type": "square", "fill": "#009ee0", "size": 30, "opacity": 1},
      "encoding": {"y": {"field": "PreAFD", "title": "PreAFD"}}
    },
    {
      "mark": {
        "type": "line",
        "color": "#eb001f",
        "interpolate": "monotone",
        "size": 3
      },
      "transform": [{"loess": "SPD", "on": "Date", "bandwidth": 0.5}],
      "encoding": {"y": {"field": "SPD", "type": "quantitative"}}
    },
    {
      "mark": {
        "type": "line",
        "color": "#000000",
        "interpolate": "monotone",
        "size": 3
      },
      "transform": [{"loess": "CDU", "on": "Date", "bandwidth": 0.5}],
      "encoding": {"y": {"field": "CDU", "type": "quantitative"}}
    },
    {
      "mark": {
        "type": "line",
        "color": "#64a12d",
        "interpolate": "monotone",
        "size": 3
      },
      "transform": [{"loess": "GRUNE", "on": "Date", "bandwidth": 0.5}],
      "encoding": {"y": {"field": "GRUNE", "type": "quantitative"}}
    },
    {
      "mark": {
        "type": "line",
        "color": "#be3075",
        "interpolate": "monotone",
        "size": 3
      },
      "transform": [{"loess": "LINKE", "on": "Date", "bandwidth": 0.5}],
      "encoding": {"y": {"field": "LINKE", "type": "quantitative"}}
    },
    {
      "mark": {
        "type": "line",
        "color": "#ffed00",
        "interpolate": "monotone",
        "size": 3
      },
      "transform": [{"loess": "FDP", "on": "Date", "bandwidth": 0.5}],
      "encoding": {"y": {"field": "FDP", "type": "quantitative"}}
    },
    {
      "mark": {
        "type": "line",
        "color": "#009ee0",
        "interpolate": "monotone",
        "size": 3
      },
      "transform": [{"loess": "AFD", "on": "Date", "bandwidth": 0.5}],
      "encoding": {"y": {"field": "AFD", "type": "quantitative"}}
    }
  ],
  "config": {}
}
  • In the editing area there will be a list of values in this format:
      {
        "Date": "2021-03-16",
        "LINKE": 30,
        "AFD": 23,
        "CDU": 19,
        "SPD": 9,
        "GRUNE": 8,
        "FDP": 6
      },
  • Copy the text above, and paste at the top of the list, on a new line below where it says "values": [
  • Replace the numbers with the results of the poll you wish to add, along with the date in YYYY-MM-DD format.
  • Check that the graph is showing up correctly on the right hand side of the screen, and that there are no warnings in the "logs" section.
  • Click the "export" button, and download the graph in SVG format
  • Before closing the Vega editor, copy the syntax from the editor and paste it in the file's description so that the next editor can use the newest version.
  • Click the "upload a new version of this file" button
  • Upload the SVG using the form
Date
Source Own work
Author PinkPanda272

Licensing

[edit]
I, the copyright holder of this work, hereby publish it under the following license:
w:en:Creative Commons
attribution share alike
This file is licensed under the Creative Commons Attribution-Share Alike 4.0 International license.
You are free:
  • to share – to copy, distribute and transmit the work
  • to remix – to adapt the work
Under the following conditions:
  • attribution – You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
  • share alike – If you remix, transform, or build upon the material, you must distribute your contributions under the same or compatible license as the original.

File history

Click on a date/time to view the file as it appeared at that time.

Date/TimeThumbnailDimensionsUserComment
current16:56, 16 March 2022Thumbnail for version as of 16:56, 16 March 2022844 × 559 (79 KB)PinkPanda272 (talk | contribs)added polls
19:29, 25 August 2021Thumbnail for version as of 19:29, 25 August 2021844 × 559 (72 KB)PinkPanda272 (talk | contribs)Added three polls, and expanded timescale as the expected snap election in September has been postponed
18:06, 22 March 2021Thumbnail for version as of 18:06, 22 March 2021844 × 559 (63 KB)PinkPanda272 (talk | contribs)Uploaded own work with UploadWizard

There are no pages that use this file.

Metadata