Density Plot

A d3-based density plot component.

Example:

<DensityPlot
    data={[ 40, 80, 20, 30, 50, 30, 40, 10, 20, 10, 20, 20 ]}
    xmin={0}
    xmax={100}
    ymax={0.5}
/>

Open interactive preview

Options:

  • bandwidth | number: smoothing parameter for the kernel density estimator. Default: 4.
  • histogram | boolean: show a histogram alongside the density plot. Default: true.
  • nBins | number: number of bins for the overlaid histogram.. Default: 8.
  • vline | object: if supplied, will display a vertical line at the supplied value with a given label. Default: none.
  • xlab | string: x-axis label. Default: 'value'.
  • xmax | number: maximum value displayed on the x-axis. Default: 1.
  • xmin | number: minimum value displayed on the x-axis. Default: 0.
  • ymax | number: maximum value displayed on the y-axis. Default: 0.15.

results matching ""

    No results matching ""