Malloy Documentation
search

Scatter charts compare two numeric values.

Model for this example

document
source: flights is duckdb.table('../data/flights.parquet') extend {
  join_one: aircraft is duckdb.table('../data/aircraft.parquet') extend {
    join_one: aircraft_models is duckdb.table('../data/aircraft_models.parquet')
      on aircraft_model_code = aircraft_models.aircraft_model_code 
  } on tail_num = aircraft.tail_num
}
document
# scatter_chart
run: flights -> {
  where: origin = 'ORD'
  group_by: seats is aircraft.aircraft_models.seats
  group_by: distance is distance
  aggregate: route_count is count(concat(origin, destination))
}
QUERY RESULTS
[
  {
    "seats": 200,
    "distance": 1437,
    "route_count": 2
  },
  {
    "seats": 179,
    "distance": 1437,
    "route_count": 2
  },
  {
    "seats": 200,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 911,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 240,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 738,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1745,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 403,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1440,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 412,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 733,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1197,
    "route_count": 1
  },
  {
    "seats": 400,
    "distance": 1846,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 2072,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1118,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1498,
    "route_count": 1
  },
  {
    "seats": 182,
    "distance": 491,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 67,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1249,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 607,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 585,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1144,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 642,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 606,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 606,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 783,
    "route_count": 1
  },
  {
    "seats": 55,
    "distance": 719,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 925,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1745,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 678,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1182,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 925,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 403,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 528,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 528,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 196,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 137,
    "route_count": 1
  },
  {
    "seats": 134,
    "distance": 491,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 67,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1829,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 607,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 607,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1012,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 972,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 972,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 978,
    "route_count": 1
  },
  {
    "seats": 37,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 264,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 925,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 733,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 1197,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 693,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1440,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 911,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 612,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 299,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 589,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1005,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1440,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1120,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1012,
    "route_count": 1
  },
  {
    "seats": 55,
    "distance": 264,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 642,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 522,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 606,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 299,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 235,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 719,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 1182,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1745,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 733,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 403,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 972,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 528,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1012,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1437,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 1515,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1498,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 137,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1249,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1249,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 409,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 473,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 621,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 621,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 130,
    "distance": 264,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 925,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 215,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 849,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 473,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 621,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1835,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1652,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1846,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1781,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 723,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 409,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 867,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 888,
    "route_count": 1
  },
  {
    "seats": 130,
    "distance": 1005,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 416,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1739,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 678,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 296,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 296,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 466,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1835,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1739,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1652,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1846,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 763,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 594,
    "route_count": 1
  },
  {
    "seats": 145,
    "distance": 491,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1700,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 2846,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 1440,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 590,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1726,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 867,
    "route_count": 1
  },
  {
    "seats": 70,
    "distance": 612,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1515,
    "route_count": 1
  },
  {
    "seats": 400,
    "distance": 1745,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1735,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1739,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 678,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 412,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 849,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1723,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1723,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 177,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1515,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 837,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 416,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1781,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1726,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 867,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 473,
    "route_count": 1
  },
  {
    "seats": 130,
    "distance": 1182,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1515,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 837,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 837,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 416,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 678,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 412,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1721,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 177,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 177,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 843,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 843,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 849,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1723,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1846,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1726,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 590,
    "route_count": 1
  },
  {
    "seats": 400,
    "distance": 4243,
    "route_count": 1
  },
  {
    "seats": 55,
    "distance": 740,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 763,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 594,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1781,
    "route_count": 1
  },
  {
    "seats": 330,
    "distance": 606,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 612,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 612,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 719,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 733,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1005,
    "route_count": 1
  },
  {
    "seats": 70,
    "distance": 412,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 900,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 783,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 264,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 802,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 528,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1120,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 2072,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 137,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 4243,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 588,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1144,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1144,
    "route_count": 1
  },
  {
    "seats": 70,
    "distance": 678,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 286,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1144,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1249,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1012,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 606,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 606,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 599,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 612,
    "route_count": 1
  },
  {
    "seats": 400,
    "distance": 888,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 235,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1182,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1182,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 589,
    "route_count": 1
  },
  {
    "seats": 55,
    "distance": 925,
    "route_count": 1
  },
  {
    "seats": 255,
    "distance": 1745,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1745,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1005,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1197,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1197,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 719,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 589,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1197,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1041,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1041,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1829,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 2116,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 607,
    "route_count": 1
  },
  {
    "seats": 55,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 599,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 911,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 240,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 802,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 299,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1440,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 299,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1182,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1005,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1120,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1120,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1041,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1829,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 783,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 783,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 316,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 264,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 240,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 802,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 235,
    "route_count": 1
  },
  {
    "seats": 145,
    "distance": 235,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 719,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 1745,
    "route_count": 1
  },
  {
    "seats": 134,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 182,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 693,
    "route_count": 1
  },
  {
    "seats": 400,
    "distance": 1721,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 911,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 235,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 403,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1829,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 4184,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 522,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 867,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 599,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 888,
    "route_count": 1
  },
  {
    "seats": 134,
    "distance": 235,
    "route_count": 1
  },
  {
    "seats": 182,
    "distance": 235,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1515,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 552,
    "route_count": 1
  },
  {
    "seats": 145,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1739,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 678,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 1721,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1721,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 723,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 843,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1081,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 849,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 1721,
    "route_count": 1
  },
  {
    "seats": 255,
    "distance": 1846,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1846,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 258,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1236,
    "route_count": 1
  },
  {
    "seats": 130,
    "distance": 606,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 473,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 621,
    "route_count": 1
  },
  {
    "seats": 400,
    "distance": 1197,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 416,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 888,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 177,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 837,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1835,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 647,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 1846,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 594,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1700,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 717,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1781,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 723,
    "route_count": 1
  },
  {
    "seats": 22,
    "distance": 409,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 647,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 647,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1723,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 296,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 177,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 334,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 740,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 717,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 723,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 621,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 888,
    "route_count": 1
  },
  {
    "seats": 149,
    "distance": 719,
    "route_count": 1
  },
  {
    "seats": 400,
    "distance": 589,
    "route_count": 1
  },
  {
    "seats": 2,
    "distance": 1723,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 296,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 296,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 416,
    "route_count": 1
  },
  {
    "seats": 172,
    "distance": 1671,
    "route_count": 1
  },
  {
    "seats": 178,
    "distance": 1726,
    "route_count": 1
  },
  {
    "seats": 200,
    "distance": 258,
    "route_count": 1
  },
  {
    "seats": 55,
    "distance": 753,
    "route_count": 1
  },
  {
    "seats": 179,
    "distance": 258,
    "route_count": 1
  }
]
SELECT 
   aircraft_models_0."seats" as "seats",
   base."distance" as "distance",
   count(distinct CONCAT(base."origin",base."destination")) as "route_count"
FROM '../data/flights.parquet' as base
 LEFT JOIN '../data/aircraft.parquet' AS aircraft_0
  ON base."tail_num"=aircraft_0."tail_num"
 LEFT JOIN '../data/aircraft_models.parquet' AS aircraft_models_0
  ON aircraft_0."aircraft_model_code"=aircraft_models_0."aircraft_model_code"
WHERE base."origin"='ORD'
GROUP BY 1,2
ORDER BY 3 desc NULLS LAST

Run as a trellis

document
run: flights -> {
  group_by: origin
  # scatter_chart
  nest: seats_by_distance_scatter_chart is  {
    group_by: seats is aircraft.aircraft_models.seats
    group_by: distance is distance
    aggregate: route_count is count(concat(origin, destination))
  }
}
QUERY RESULTS
[
  {
    "origin": "ABE",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 149,
        "distance": 692,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 77,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 503,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 339,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 692,
        "route_count": 1
      },
      {
        "seats": 37,
        "distance": 339,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 906,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 480,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 253,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 480,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 906,
        "route_count": 1
      },
      {
        "seats": 70,
        "distance": 55,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ABI",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 39,
        "distance": 158,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 307,
        "route_count": 1
      },
      {
        "seats": 37,
        "distance": 158,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ABQ",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 140,
        "distance": 1670,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 580,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1240,
        "route_count": 1
      },
      {
        "seats": 182,
        "distance": 981,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1269,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 580,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 759,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 744,
        "route_count": 1
      },
      {
        "seats": 145,
        "distance": 981,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 493,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 349,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 759,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 289,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 1118,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 277,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 349,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 487,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 487,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 321,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 277,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 349,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 569,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 289,
        "route_count": 1
      },
      {
        "seats": 134,
        "distance": 981,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 321,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 223,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 718,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 1121,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1121,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 1118,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 628,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1497,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 718,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 628,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 889,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 328,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 1497,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 223,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 889,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 328,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 332,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1552,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 934,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1269,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 744,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 677,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1111,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 934,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 677,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 332,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 1552,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 1111,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 1180,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1180,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 934,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ABY",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 55,
        "distance": 146,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 146,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 146,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ACK",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 37,
        "distance": 218,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 218,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ACT",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 37,
        "distance": 89,
        "route_count": 1
      },
      {
        "seats": 39,
        "distance": 89,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ACY",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 55,
        "distance": 542,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "AEX",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 37,
        "distance": 190,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 274,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 285,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 190,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "AGS",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 55,
        "distance": 143,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 143,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 821,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 663,
        "route_count": 1
      },
      {
        "seats": 37,
        "distance": 663,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ALB",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 37,
        "distance": 145,
        "route_count": 2
      },
      {
        "seats": 149,
        "distance": 288,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 723,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 1073,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 723,
        "route_count": 1
      },
      {
        "seats": 70,
        "distance": 212,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 143,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 723,
        "route_count": 1
      },
      {
        "seats": 70,
        "distance": 367,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 424,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 645,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 623,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1073,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 288,
        "route_count": 1
      },
      {
        "seats": 70,
        "distance": 318,
        "route_count": 1
      },
      {
        "seats": 145,
        "distance": 488,
        "route_count": 1
      },
      {
        "seats": 182,
        "distance": 488,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 852,
        "route_count": 1
      },
      {
        "seats": 37,
        "distance": 143,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 212,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 367,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 717,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 2237,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 623,
        "route_count": 1
      },
      {
        "seats": 22,
        "distance": 723,
        "route_count": 1
      },
      {
        "seats": 37,
        "distance": 424,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 318,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 1073,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "AMA",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 172,
        "distance": 313,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 277,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 519,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 758,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 324,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 277,
        "route_count": 1
      },
      {
        "seats": 39,
        "distance": 313,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 758,
        "route_count": 1
      },
      {
        "seats": 140,
        "distance": 324,
        "route_count": 1
      },
      {
        "seats": 37,
        "distance": 313,
        "route_count": 1
      },
      {
        "seats": 22,
        "distance": 313,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ANC",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 330,
        "distance": 1449,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 3417,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 1449,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 2406,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 2345,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2518,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1449,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 1542,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 1449,
        "route_count": 1
      },
      {
        "seats": 275,
        "distance": 2986,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 261,
        "route_count": 1
      },
      {
        "seats": 275,
        "distance": 2797,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2846,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2018,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 1449,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2406,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 261,
        "route_count": 1
      },
      {
        "seats": 275,
        "distance": 2518,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 2406,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 2125,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2125,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2986,
        "route_count": 1
      }
    ]
  },
  {
    "origin": "ATL",
    "seats_by_distance_scatter_chart": [
      {
        "seats": 55,
        "distance": 227,
        "route_count": 2
      },
      {
        "seats": 178,
        "distance": 859,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 191,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 259,
        "route_count": 1
      },
      {
        "seats": 70,
        "distance": 227,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 366,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 547,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 303,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 389,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 619,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 595,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 302,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 272,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 2139,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1919,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 483,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 223,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 146,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 259,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 366,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 547,
        "route_count": 1
      },
      {
        "seats": 172,
        "distance": 732,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 171,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 745,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 745,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 151,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 689,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 377,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 760,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 453,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 692,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 403,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 590,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1891,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 874,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 2182,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1547,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1589,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 146,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 946,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 227,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 432,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 1199,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 171,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 508,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 306,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 153,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 533,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 689,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 760,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 389,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 403,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 147,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 952,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 481,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 321,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1599,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 406,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 152,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 264,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1269,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 143,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 164,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 164,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 134,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 449,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 554,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 432,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1199,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 594,
        "route_count": 1
      },
      {
        "seats": 134,
        "distance": 594,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 350,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 581,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 581,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 377,
        "route_count": 1
      },
      {
        "seats": 134,
        "distance": 332,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 606,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 576,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 576,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 446,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 732,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1747,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 79,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 590,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 669,
        "route_count": 1
      },
      {
        "seats": 134,
        "distance": 906,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 906,
        "route_count": 1
      },
      {
        "seats": 70,
        "distance": 526,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 356,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 481,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 515,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 215,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 321,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2116,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 223,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 674,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 146,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 214,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 191,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 554,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 83,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 373,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 273,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 153,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 640,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 533,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 341,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1946,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 305,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 79,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 302,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 425,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 445,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 483,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 406,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 692,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 143,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 238,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 259,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 227,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 83,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 373,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 1199,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 732,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 533,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 270,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 761,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 317,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 545,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 526,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 272,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 152,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 449,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 712,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1941,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1185,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 350,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 352,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 151,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 595,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2130,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 2130,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1900,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 606,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 606,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 516,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 2172,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 665,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1587,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 749,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 874,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 215,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 793,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 264,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 134,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 227,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 876,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 373,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 300,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 644,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 352,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 696,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 533,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 689,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 270,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1747,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 302,
        "route_count": 1
      },
      {
        "seats": 182,
        "distance": 906,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 545,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 247,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 1587,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 515,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 357,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 812,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 576,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 528,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 373,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 732,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 241,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 533,
        "route_count": 1
      },
      {
        "seats": 200,
        "distance": 533,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 432,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 1946,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 305,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 761,
        "route_count": 1
      },
      {
        "seats": 145,
        "distance": 332,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 595,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 443,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 425,
        "route_count": 1
      },
      {
        "seats": 22,
        "distance": 606,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 665,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 526,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 272,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 903,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1993,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 445,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 152,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 589,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 852,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 3417,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 765,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 106,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 363,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 547,
        "route_count": 1
      },
      {
        "seats": 145,
        "distance": 594,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 594,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 331,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 241,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1747,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1946,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 595,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 2172,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1587,
        "route_count": 1
      },
      {
        "seats": 179,
        "distance": 2139,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 552,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 227,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 692,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 813,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 576,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 106,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 554,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 745,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 331,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 306,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 153,
        "route_count": 1
      },
      {
        "seats": 32,
        "distance": 342,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 151,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 270,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 303,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 761,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 692,
        "route_count": 1
      },
      {
        "seats": 130,
        "distance": 332,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 1900,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 606,
        "route_count": 1
      },
      {
        "seats": 358,
        "distance": 545,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2172,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 665,
        "route_count": 1
      },
      {
        "seats": 70,
        "distance": 665,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 2092,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 223,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 227,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 859,
        "route_count": 1
      },
      {
        "seats": 178,
        "distance": 449,
        "route_count": 1
      },
      {
        "seats": 76,
        "distance": 191,
        "route_count": 1
      },
      {
        "seats": 330,
        "distance": 1199,
        "route_count": 1
      },
      {
        "seats": 149,
        "distance": 745,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 153,
        "route_count": 1
      },
      {
        "seats": 55,
        "distance": 781,
        "route_count": 1
      },
      {
        "seats":