Cumulative plot, small

API
Dataset
Other graphics for same dataset
Cumulative serology test numbers 2021-09-16T07:50:12.403Z
Total serology test numbers 2024-02-19T07:06:54.211Z
Weekly serology test numbers 2024-03-21T05:40:22.141Z
{
  "$schema": "https://vega.github.io/schema/vega-lite/v5.json",
  "data": {
    "url": "https://datagraphics.dc.scilifelab.se/api/dataset/6d6f551abc10413a97a6ab64ebac46bd.csv"
  },
  "width": 450,
  "height": 150,
  "transform": [
    {
      "sort": [
        {
          "field": "week"
        }
      ],
      "window": [
        {
          "op": "sum",
          "field": "count",
          "as": "cumulative_count"
        }
      ],
      "groupby": [
        "class"
      ],
      "frame": [
        null,
        0
      ]
    }
  ],
  "mark": {
    "type": "line",
    "tooltip": true,
    "point": {
      "filled": false,
      "fill": "white"
    }
  },
  "encoding": {
    "x": {
      "title": "Week",
      "field": "week",
      "type": "nominal",
      "axis": {
        "labelAngle": 90,
        "labelOverlap": "parity"
      }
    },
    "y": {
      "title": "Cumulative number of tests",
      "field": "cumulative_count",
      "type": "quantitative"
    },
    "color": {
      "field": "class",
      "type": "nominal",
      "scale": {
        "domain": [
          "R&D",
          "negative",
          "positive"
        ],
        "range": [
          "#c7c7c7",
          "#8fd7f9",
          "#ef9292"
        ]
      },
      "legend": {
        "title": "Test results"
      }
    }
  }
}
Owner: arnold
Modified 2022-01-11T04:00:14.118Z
Created 2021-01-12T15:32:42.735Z

DataGraphics 1.0.4