Skip to content

Violin

Kernel-density violins per group: each body is the distribution's shape mirrored about its axis, with a box inside (IQR bar, whiskers, a punched-out median) or dashed quartile rules, and an optional strip of the raw samples.

$149 once · every Pro piece

Customize

Two series split every violin down the middle, with a legend that isolates and toggles a half. Point at a violin and a hot chord cuts across it at your height, exactly as wide as the density there, while the panel reads the value, the density and its percentile; ↑/↓ move that slice from the keyboard. Violins unfold from their axis as the reveal passes and morph when the data or bandwidth changes.

Install

npx shadcn@latest add @obsyde/violin

Needs your licence key · Get Pro

Usage

Import it from where the CLI puts it, or copy the files below by hand.

import { Violin } from '@/components/obsyde/ember/violin/Violin';

export function Example() {
  return (
    <Violin inner="box" />
  );
}

Files

What you get with Pro: plain React, TypeScript and CSS, with no dependencies.

  • ember/violin/Violin.tsxcomponent
  • ember/violin/violin.cssstyles
  • ember/violin/ViolinDemo.tsxdemo
  • ember/viz-kit/viz-kit.cssshared
  • ember/viz-kit/Tooltip.tsxshared
  • ember/viz-kit/focus.tsshared
  • ember/viz-kit/patterns.tsxshared
  • ember/viz-kit/roll.tsshared
  • ember/shared/rolling-number.cssshared
  • ember/shared/spring.tsshared
  • ember/shared/accent.tsshared
  • ember/viz-kit/scale.tsshared
  • ember/viz-kit/motion.tsshared
  • ember/viz-kit/chart.tsxshared
  • ember/shared/ember.cssshared
  • ember/viz-kit/touch.tsshared
  • ember/viz-kit/keyboard.tsshared
  • ember/viz-kit/size.tsshared
  • ember/viz-kit/States.tsxshared
  • ember/viz-kit/shape.tsshared
  • ember/viz-kit/Legend.tsxshared
  • ember/viz-kit/Grid.tsxshared
  • ember/viz-kit/demo.tsxshared
  • ember/viz-kit/demo.cssshared
  • ember/viz-kit/Axis.tsxshared

API

PropTypeDefault
accentAccent'ember' | 'volt' | 'arc''ember'
splitSplitbooleanfalse
innerInner'box' | 'quartiles' | 'none''box'
stripSample stripbooleanfalse
bandwidthBandwidthnumber1
groupsGroupsnumber5
tooltipTooltip'panel' | 'none''panel'
sliceSlice'quiet' | 'hot''quiet'
crosshairCrosshair'none' | 'dashed''none'
patternPattern'none' | 'diagonal-up' | 'diagonal-down' | 'dots' | 'vertical' | 'crosshatch''none'
backgroundBackground'grid' | 'dots' | 'hatch' | 'none''grid'
revealReveal'sweep' | 'cool' | 'rise' | 'fade' | 'none''sweep'
statusStatus'ready' | 'loading' | 'empty''ready'
heightHeightnumber300
seedSeednumber3