From 52bc27d7d2a43040fdc48b275a3df2668224095a Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Fri, 26 Jun 2020 19:28:19 +1000 Subject: [PATCH] smooth area path --- ts/src/stats/histogram-graph.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ts/src/stats/histogram-graph.ts b/ts/src/stats/histogram-graph.ts index 118c58e98..a072dc459 100644 --- a/ts/src/stats/histogram-graph.ts +++ b/ts/src/stats/histogram-graph.ts @@ -11,7 +11,7 @@ import { select, mouse } from "d3-selection"; import { cumsum, max, Bin } from "d3-array"; import { scaleLinear, ScaleLinear, ScaleSequential } from "d3-scale"; import { axisBottom, axisLeft } from "d3-axis"; -import { area } from "d3-shape"; +import { area, curveBasis } from "d3-shape"; import { showTooltip, hideTooltip } from "./tooltip"; import { GraphBounds } from "./graphs"; @@ -108,6 +108,7 @@ export function histogramGraph( .attr( "d", area() + .curve(curveBasis) .x((d, idx) => { if (idx === 0) { return x(data.bins[0].x0!);