Line and column

Revenue columns with a margin line on a second axis.

Chart type
Line line
Tier
Free Core
Collection
Mixed / combo
Render
Live, site theme
View .md Agent setup
LIVE/mixed/line-column1 of 6 in Mixed

Configuration

Raw Standalone
const options = {
  chart: {
    height: 380,
    fontFamily: "Inter, Geist, \"IBM Plex Sans\", system-ui, sans-serif",
    type: "line",
    toolbar: {
      show: false
    }
  },
  series: [
    {
      name: "Revenue k€",
      type: "column",
      data: [547, 314, 535, 384, 456, 435, 378, 423, 373, 405, 383, 331]
    },
    {
      name: "Margin %",
      type: "line",
      data: [31.2, 29.4, 30.3, 29.1, 27.9, 27.4, 27.5, 26, 27.7, 28.5, 27.1, 27.2]
    }
  ],
  stroke: {
    width: [0, 3]
  },
  xaxis: {
    categories: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"]
  },
  yaxis: [
    {
      title: {
        text: "Revenue k€"
      }
    },
    {
      opposite: true,
      title: {
        text: "Margin %"
      }
    }
  ],
  dataLabels: {
    enabled: true,
    enabledOnSeries: [1]
  },
  title: {
    text: "Revenue and margin"
  },
  theme: {
    mode: "light",
    preset: "coastal"
  }
}

const chart = new WestCoastCharts(document.querySelector('#chart'), options)
chart.render()