Slope and bump
Compare two moments with a slope chart or follow rank across many periods with a bump chart. Both are line charts with a few extra spec fields.
A slope chart draws one line per series between two points in time, so every crossing is a change in rank and every steep line is a large move. A bump chart plots rank rather than value across several periods, and shows who moved up or down at each step.
Neither is a separate mark. Both are mark: "line" with a few public spec fields. Use a regular line chart when the exact values over many periods matter more than the order, and a range chart when you want the size of each gap between two values.
A slope chart
Two ordinal x values, one line per brand. The values live on the labels, so axis: false removes the y axis and its gridlines. Line marks already fit the y axis to the data range (zero: false) and curve monotonically. The recipe sets both explicitly so the spec stays readable on its own. endpointLabels with ends: "both" puts a label column at each edge.
{
"mark": "line",
"data": [
{
"year": "2019",
"brand": "Samsung",
"share": 0.216
},
{
"year": "2024",
"brand": "Samsung",
"share": 0.19
},
{
"year": "2019",
"brand": "Huawei",
"share": 0.176
},
{
"year": "2024",
"brand": "Huawei",
"share": 0.043
},
{
"year": "2019",
"brand": "Apple",
"share": 0.139
},
{
"year": "2024",
"brand": "Apple",
"share": 0.187
},
{
"year": "2019",
"brand": "Xiaomi",
"share": 0.092
},
{
"year": "2024",
"brand": "Xiaomi",
"share": 0.136
},
{
"year": "2019",
"brand": "Oppo",
"share": 0.083
},
{
"year": "2024",
"brand": "Oppo",
"share": 0.087
}
],
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label value",
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Huawei's share fell from 18% to 4% as Apple and Xiaomi gained",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
}import { Chart } from "@opendata-ai/openchart-react";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label value",
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Huawei's share fell from 18% to 4% as Apple and Xiaomi gained",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
export function Example() {
return <Chart spec={spec} />;
}
<script setup lang="ts">
import { Chart } from "@opendata-ai/openchart-vue";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label value",
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Huawei's share fell from 18% to 4% as Apple and Xiaomi gained",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
</script>
<template>
<Chart :spec="spec" />
</template>
<script lang="ts">
import { Chart } from "@opendata-ai/openchart-svelte";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label value",
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Huawei's share fell from 18% to 4% as Apple and Xiaomi gained",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
</script>
<Chart {spec} />
import { createChart } from "@opendata-ai/openchart-vanilla";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label value",
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Huawei's share fell from 18% to 4% as Apple and Xiaomi gained",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
const container = document.getElementById("chart");
if (!container) throw new Error('Add <div id="chart"></div> to the page first.');
createChart(container, spec);
Different labels on each side
content takes an object to set the two columns separately. Here leading joins the name and value on the left and trailing prints the value alone on the right, so the name is not repeated. Because the spec sets endpointLabels explicitly, the label columns stay at narrow widths where automatic endpoint labels would hand off to a legend.
{
"mark": "line",
"data": [
{
"year": "2019",
"brand": "Samsung",
"share": 0.216
},
{
"year": "2024",
"brand": "Samsung",
"share": 0.19
},
{
"year": "2019",
"brand": "Huawei",
"share": 0.176
},
{
"year": "2024",
"brand": "Huawei",
"share": 0.043
},
{
"year": "2019",
"brand": "Apple",
"share": 0.139
},
{
"year": "2024",
"brand": "Apple",
"share": 0.187
},
{
"year": "2019",
"brand": "Xiaomi",
"share": 0.092
},
{
"year": "2024",
"brand": "Xiaomi",
"share": 0.136
},
{
"year": "2019",
"brand": "Oppo",
"share": 0.083
},
{
"year": "2024",
"brand": "Oppo",
"share": 0.087
}
],
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": {
"leading": "label value",
"trailing": "value"
},
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Name and value on the left, value alone on the right",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
}import { Chart } from "@opendata-ai/openchart-react";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": {
"leading": "label value",
"trailing": "value"
},
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Name and value on the left, value alone on the right",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
export function Example() {
return <Chart spec={spec} />;
}
<script setup lang="ts">
import { Chart } from "@opendata-ai/openchart-vue";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": {
"leading": "label value",
"trailing": "value"
},
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Name and value on the left, value alone on the right",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
</script>
<template>
<Chart :spec="spec" />
</template>
<script lang="ts">
import { Chart } from "@opendata-ai/openchart-svelte";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": {
"leading": "label value",
"trailing": "value"
},
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Name and value on the left, value alone on the right",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
</script>
<Chart {spec} />
import { createChart } from "@opendata-ai/openchart-vanilla";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 10 rows, as in the Spec tab; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": "line",
"encoding": {
"x": {
"field": "year",
"type": "ordinal"
},
"y": {
"field": "share",
"type": "quantitative",
"axis": false,
"scale": {
"zero": false
}
},
"color": {
"field": "brand",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": {
"leading": "label value",
"trailing": "value"
},
"format": ".0%"
},
"legend": {
"show": false
},
"chrome": {
"title": "Name and value on the left, value alone on the right",
"subtitle": "Share of global smartphone shipments, 2019 vs 2024"
}
};
const container = document.getElementById("chart");
if (!container) throw new Error('Add <div id="chart"></div> to the page first.');
createChart(container, spec);
A bump chart
The y axis is the finishing position. scale: { reverse: true } puts first place at the top, and axis.values with format: "ordinal" prints one tick per rank as 1st, 2nd and so on. point: true marks every step. Line marks already curve monotonically; the recipe sets interpolate: "monotone" explicitly so the spec stays readable on its own. Series that tie share a row.
{
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"data": [
{
"season": "2019",
"team": "Mercedes",
"position": 1
},
{
"season": "2020",
"team": "Mercedes",
"position": 1
},
{
"season": "2021",
"team": "Mercedes",
"position": 1
},
{
"season": "2022",
"team": "Mercedes",
"position": 3
},
{
"season": "2023",
"team": "Mercedes",
"position": 2
},
{
"season": "2024",
"team": "Mercedes",
"position": 4
},
// … 24 more rows; Copy includes them
],
"encoding": {
"x": {
"field": "season",
"type": "ordinal"
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4,
5,
6
],
"format": "ordinal"
}
},
"color": {
"field": "team",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "McLaren went from midfield to champions",
"subtitle": "Formula 1 constructors championship, final position by season"
}
}import { Chart } from "@opendata-ai/openchart-react";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 30 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"encoding": {
"x": {
"field": "season",
"type": "ordinal"
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4,
5,
6
],
"format": "ordinal"
}
},
"color": {
"field": "team",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "McLaren went from midfield to champions",
"subtitle": "Formula 1 constructors championship, final position by season"
}
};
export function Example() {
return <Chart spec={spec} />;
}
<script setup lang="ts">
import { Chart } from "@opendata-ai/openchart-vue";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 30 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"encoding": {
"x": {
"field": "season",
"type": "ordinal"
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4,
5,
6
],
"format": "ordinal"
}
},
"color": {
"field": "team",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "McLaren went from midfield to champions",
"subtitle": "Formula 1 constructors championship, final position by season"
}
};
</script>
<template>
<Chart :spec="spec" />
</template>
<script lang="ts">
import { Chart } from "@opendata-ai/openchart-svelte";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 30 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"encoding": {
"x": {
"field": "season",
"type": "ordinal"
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4,
5,
6
],
"format": "ordinal"
}
},
"color": {
"field": "team",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "McLaren went from midfield to champions",
"subtitle": "Formula 1 constructors championship, final position by season"
}
};
</script>
<Chart {spec} />
import { createChart } from "@opendata-ai/openchart-vanilla";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 30 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"encoding": {
"x": {
"field": "season",
"type": "ordinal"
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4,
5,
6
],
"format": "ordinal"
}
},
"color": {
"field": "team",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "McLaren went from midfield to champions",
"subtitle": "Formula 1 constructors championship, final position by season"
}
};
const container = document.getElementById("chart");
if (!container) throw new Error('Add <div id="chart"></div> to the page first.');
createChart(container, spec);
Ranks from scores
If your data holds scores rather than ranks, derive the rank with a window transform. op: "rank" ranks the rows within each group, groupby makes each date its own ranking, and sort sets the direction. The result lands in the field named by as, which the y channel then reads. At the first date every index starts at 0% and ties for first.
{
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"data": [
{
"date": "2022-01-01",
"totalReturn": 0,
"index": "S&P 500"
},
{
"date": "2022-04-01",
"totalReturn": -5.3,
"index": "S&P 500"
},
{
"date": "2022-07-01",
"totalReturn": -13.1,
"index": "S&P 500"
},
{
"date": "2022-10-01",
"totalReturn": -17.7,
"index": "S&P 500"
},
{
"date": "2023-01-01",
"totalReturn": -18.1,
"index": "S&P 500"
},
{
"date": "2023-04-01",
"totalReturn": -8.2,
"index": "S&P 500"
},
// … 58 more rows; Copy includes them
],
"transform": [
{
"window": [
{
"op": "rank",
"field": "totalReturn",
"as": "position"
}
],
"sort": [
{
"field": "totalReturn",
"order": "descending"
}
],
"groupby": [
"date"
]
}
],
"encoding": {
"x": {
"field": "date",
"type": "temporal",
"axis": {
"format": "%b '%y",
"tickCount": 6
}
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4
],
"format": "ordinal"
}
},
"color": {
"field": "index",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "The window transform turns scores into ranks",
"subtitle": "Rank of cumulative total return among four US equity indices, quarterly"
}
}import { Chart } from "@opendata-ai/openchart-react";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 64 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"transform": [
{
"window": [
{
"op": "rank",
"field": "totalReturn",
"as": "position"
}
],
"sort": [
{
"field": "totalReturn",
"order": "descending"
}
],
"groupby": [
"date"
]
}
],
"encoding": {
"x": {
"field": "date",
"type": "temporal",
"axis": {
"format": "%b '%y",
"tickCount": 6
}
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4
],
"format": "ordinal"
}
},
"color": {
"field": "index",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "The window transform turns scores into ranks",
"subtitle": "Rank of cumulative total return among four US equity indices, quarterly"
}
};
export function Example() {
return <Chart spec={spec} />;
}
<script setup lang="ts">
import { Chart } from "@opendata-ai/openchart-vue";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 64 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"transform": [
{
"window": [
{
"op": "rank",
"field": "totalReturn",
"as": "position"
}
],
"sort": [
{
"field": "totalReturn",
"order": "descending"
}
],
"groupby": [
"date"
]
}
],
"encoding": {
"x": {
"field": "date",
"type": "temporal",
"axis": {
"format": "%b '%y",
"tickCount": 6
}
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4
],
"format": "ordinal"
}
},
"color": {
"field": "index",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "The window transform turns scores into ranks",
"subtitle": "Rank of cumulative total return among four US equity indices, quarterly"
}
};
</script>
<template>
<Chart :spec="spec" />
</template>
<script lang="ts">
import { Chart } from "@opendata-ai/openchart-svelte";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 64 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"transform": [
{
"window": [
{
"op": "rank",
"field": "totalReturn",
"as": "position"
}
],
"sort": [
{
"field": "totalReturn",
"order": "descending"
}
],
"groupby": [
"date"
]
}
],
"encoding": {
"x": {
"field": "date",
"type": "temporal",
"axis": {
"format": "%b '%y",
"tickCount": 6
}
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4
],
"format": "ordinal"
}
},
"color": {
"field": "index",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "The window transform turns scores into ranks",
"subtitle": "Rank of cumulative total return among four US equity indices, quarterly"
}
};
</script>
<Chart {spec} />
import { createChart } from "@opendata-ai/openchart-vanilla";
import type { ChartSpec } from "@opendata-ai/openchart-core";
import "@opendata-ai/openchart-core/styles.css";
const data = [/* 64 rows; Copy includes them */];
const spec: ChartSpec = {
data,
"mark": {
"type": "line",
"interpolate": "monotone",
"point": true
},
"transform": [
{
"window": [
{
"op": "rank",
"field": "totalReturn",
"as": "position"
}
],
"sort": [
{
"field": "totalReturn",
"order": "descending"
}
],
"groupby": [
"date"
]
}
],
"encoding": {
"x": {
"field": "date",
"type": "temporal",
"axis": {
"format": "%b '%y",
"tickCount": 6
}
},
"y": {
"field": "position",
"type": "quantitative",
"scale": {
"reverse": true,
"zero": false
},
"axis": {
"values": [
1,
2,
3,
4
],
"format": "ordinal"
}
},
"color": {
"field": "index",
"type": "nominal"
}
},
"endpointLabels": {
"ends": "both",
"content": "label",
"showMarker": false
},
"legend": {
"show": false
},
"chrome": {
"title": "The window transform turns scores into ranks",
"subtitle": "Rank of cumulative total return among four US equity indices, quarterly"
}
};
const container = document.getElementById("chart");
if (!container) throw new Error('Add <div id="chart"></div> to the page first.');
createChart(container, spec);
Fields that matter
| Field | What it does |
|---|---|
mark |
"line". For a bump chart, an object with point: true, plus interpolate: "monotone" if you want it explicit. |
encoding.y.axis |
false removes the axis, as on a slope chart. values and format: "ordinal" print rank ticks. |
encoding.y.scale |
zero: false is already the line default and is set for clarity. reverse: true puts rank 1 at the top. |
endpointLabels.ends |
"both" adds a label column on the left edge as well as the right. |
endpointLabels.content |
"label", "value" or "label value", or an object with leading and trailing. |
transform |
A window rank turns scores into positions grouped by period. |
legend |
{ show: false } hides the legend when the labels name every series. |
Related
- Line for values over many periods.
- Range for the gap between two values.
- Bar for a ranking at a single moment.
- Sparkline for a trend with no axes.
- Marks reference lists the channels and options each mark type takes.