Charts / React BI charts / Comparison
Actual and forecast against plan and prior year per period, with the absolute variance as green and red bars and the relative variance as pins, all on one aligned scale with a totals column.
React component VarianceChart, data through props. Side by side: who, which source, which version is ahead. Tags: variance, ibcs, plan-vs-actual, budget, forecast, prior-year, hichert, financial-reporting.
npm i klar-charts
import 'klar-charts/styles.css'
import { ThemeScope, VarianceChart } from 'klar-charts'
# or copy the source:
npx shadcn@latest add https://klar.run/r/bi-variance.json<VarianceChart
data={data}
orientation={view === 'months' ? 'vertical' : 'horizontal'}
compare={cmp as 'plan' | 'prior'}
totalLabel={view === 'months' ? 'FY' : 'Total'}
format={eurM}
unit="€M"
height={view === 'months' ? 460 : 400}
/>