# SmartVisuals Histogram for Power BI

> Histograms for Power BI with named bin rules, custom edges, percentile lines and normal curves, dynamic in the Service. Premium: Cp, Cpk, Cpm and spec limits.

- Page: https://www.smartvisuals.io/visuals/histogram
- Fields and settings: https://www.smartvisuals.io/visuals/histogram/settings
- Microsoft Marketplace: https://marketplace.microsoft.com/en-us/product/smartvisuals.smartvisuals-histogram?tab=overview
- Package: https://www.smartvisuals.io/downloads/smartvisuals-histogram-1.0.0.0.pbiviz
- Sample report (zipped .pbip): https://www.smartvisuals.io/samples/smartvisuals-histogram-sample-1.0.0.0.zip
- Price: Free tier for every viewer; premium $1.99 per user per month or $19 per user per year on Microsoft Marketplace, with a 30-day free trial. Premium works in edit mode without a licence; unlicensed viewers see the free tier, never a blocked visual.
- Certified by Microsoft: no
- Version: 1.0.0.0
- GUID (visualType and publicCustomVisuals): `smartvisualsHistogram0B2CDFBFD376F32FDEA400260852BF18`

## What is free

- **Bins you can name**: Freedman-Diaconis (default), Sturges, Scott, Rice, square root, Doane, auto, a fixed number or a fixed width, with round bin edges.
- **Bins you choose**: Type your own edges (0, 10, 12, 15, 20) or set where a bin starts; values outside your edges are counted in the footnote.
- **Reference lines**: Mean, median and up to four percentiles (P90, P95), for all data or per group, by the quartile definition you pick.
- **Bars and curves**: Count, percent of group or density, with a cumulative % line, a density curve and a fitted normal curve.
- **Groups on shared bins**: Overlaid, stacked or one row per group, picked automatically until you choose.
- **Dynamic in the Service**: No Desktop-only bins; up to 150,000 rows or a value column plus Count, a smart caption and a methods footnote.
- **Four themes and native behaviour**: SmartVisuals, Dark, Clean and Slate themes, keyboard navigation, high-contrast mode and two languages (English, Czech).

## What premium adds

- **Spec limits your way**: Typed, or from LSL, USL and Target measures so every product or line is judged against its own specification and follows the slicers.
- **Every capability index**: Cp, Cpk, Cpl, Cpu, Cpm, Pp and Ppk following AIAG, with Cpm against the target. An index that cannot be computed is not shown.
- **Out of spec and control limits**: Share and ppm expected outside spec, and plus or minus 3 sigma control limits.
- **Significance and weights**: Tests between groups and weighted statistics with an effective base.
- **Advanced density and small multiples**: Six density kernels and one panel per plant, product or region on a shared scale.

## Fields

| Field | Internal name | Takes | Needed | What it is for |
| --- | --- | --- | --- | --- |
| Group | `group` | Column | Optional | One distribution per group along the axis |
| Split By | `series` | Column | Optional | Side-by-side distributions within each group; two levels make a split violin |
| Sample / ID | `detail` | Column | Optional | The observation grain, e.g. Measurement ID - without it Power BI sums the values |
| Value | `value` | Measure | Optional | The observed value per Sample / ID |
| Value (as column) | `valueColumn` | Column | Optional | For large data: the value itself as a column, with Count as the measure |
| Count | `count` | Measure | Optional | How many observations have this value (with Value as column) |
| Weight | `weight` | Measure | Optional | Survey or sampling weight per observation (premium) |
| Small Multiples | `facet` | Column | Optional | One panel per value, shared axis (premium) |
| Tooltips | `tooltips` | Measure | Optional | Extra fields in point tooltips |
| Lower Spec Limit (LSL) | `lsl` | Measure | Optional | Lower spec limit per group, e.g. from a spec table (premium); replaces the typed LSL |
| Upper Spec Limit (USL) | `usl` | Measure | Optional | Upper spec limit per group, e.g. from a spec table (premium); replaces the typed USL |
| Spec Target | `target` | Measure | Optional | Target per group for Cpm and the target line (premium); replaces the typed target |

## Format pane

Each card is a key under `visual.objects` in a PBIR visual.json; each setting is a property of it. Toggles take `true`/`false`, choices and text a value in single quotes (`'auto'`), numbers a `D` suffix (`12D`).

### Layout (`layout`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Orientation | `orientation` | `vertical` (Vertical), `horizontal` (Horizontal) |
| Sort Groups By | `sortGroups` | `data` (Data order), `name` (Name), `median` (Median), `mean` (Mean), `n` (Number of observations), `iqr` (Spread (IQR)) |
| Sort Direction | `sortDirection` | `asc` (Ascending), `desc` (Descending) |
| Hide Groups With Fewer Than | `minGroupSize` | Number |
| Space Between Groups (%) | `groupGap` | Number |

### Statistics (`stats`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Quartile Method | `quartileMethod` | `linear` (Excel / DAX inclusive: PERCENTILE.INC (type 7)), `weibull` (Excel / DAX exclusive: PERCENTILE.EXC, Minitab, SPSS (type 6)), `tukey` (Tukey's hinges (R fivenum)), `median_unbiased` (Median-unbiased (type 8)), `hazen` (Midpoint, Hazen (type 5)), `normal_unbiased` (Normal-unbiased (type 9)), `interpolated_inverted_cdf` (Linear CDF (type 4)), `inverted_cdf` (Nearest rank, inverted CDF (type 1)), `averaged_inverted_cdf` (Averaged inverted CDF (type 2)), `closest_observation` (Closest observation (type 3)) |

### Density (`density`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Bandwidth Rule | `bandwidthRule` | `scott` (Scott), `silverman` (Silverman), `nrd0` (Silverman rule of thumb (R default)) |
| Smoothness (%) | `smoothness` | Number |
| Trim to Data Range | `trim` | On / off |
| Violin Width | `scale` | `area` (Equal area), `width` (Equal width), `count` (By number of observations) |
| Inside the Violin | `inner` | `box` (Box), `quartiles` (Quartile lines), `points` (Points), `none` (Nothing) |
| Show Rain (Points) | `rain` | On / off |
| Ridge Overlap (%) | `overlap` | Number |
| Fill Opacity (%, -1 = theme) | `fillOpacity` | Number |

### Bins (`bins`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Binning | `rule` | `fd` (Freedman-Diaconis), `sturges` (Sturges), `scott` (Scott), `rice` (Rice), `sqrt` (Square root), `doane` (Doane), `auto` (Auto (numpy)), `count` (Fixed number of bins), `width` (Fixed bin width), `custom` (Custom bin edges) |
| Round Bin Edges | `nice` | On / off |
| Number of Bins | `count` | Number |
| Bin Width | `width` | Number |
| Bin Edges | `edges` | Text |
| Set Bin Start | `useAnchor` | On / off |
| A Bin Starts At | `anchor` | Number |
| Bar Height | `measure` | `count` (Count), `percent` (Percent of group), `density` (Density) |
| Groups | `groupMode` | `auto` (Auto (overlaid up to two, else rows)), `overlay` (Overlaid), `stacked` (Stacked), `rows` (One row per group) |
| Gap Between Bars (px) | `gap` | Number |
| Cumulative % Line | `showCumulative` | On / off |
| Density Curve | `showDensity` | On / off |
| Fitted Normal Curve | `showNormal` | On / off |
| Bar Height Axis Title | `showHeightTitle` | On / off |

### Compare Groups (`compare`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Test Differences | `show` | On / off |
| Test | `test` | `welch` (Welch t-test (means)), `mannwhitney` (Mann-Whitney U (ranks)) |
| Overall Test | `omnibus` | `welchAnova` (Welch's ANOVA), `anova` (One-way ANOVA), `kruskal` (Kruskal-Wallis) |
| Multiple Comparisons | `correction` | `holm` (Holm), `bonferroni` (Bonferroni), `none` (None) |
| Confidence | `level` | `90` (90 %), `95` (95 %), `99` (99 %) |
| Show As | `display` | `brackets` (Brackets with stars), `letters` (Letters (A, B, C)) |
| Pairs | `pairs` | `all` (All pairs), `first` (Each vs the first group), `adjacent` (Neighbours only) |
| Show Non-significant Pairs | `showNs` | On / off |

### Spec Limits & Capability (`spec`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Lower Spec Limit | `useLsl` | On / off |
| LSL | `lsl` | Number |
| Upper Spec Limit | `useUsl` | On / off |
| USL | `usl` | Number |
| Target | `useTarget` | On / off |
| Target Value | `target` | Number |
| Show Cp, Cpk, Cpl, Cpu, Cpm, Pp, Ppk | `showIndices` | On / off |
| Control Limits (±3σ within) | `showControl` | On / off |
| Limit Color | `color` | Colour |

### Advanced Density (`kde`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Kernel | `kernel` | `gaussian` (Gaussian), `epanechnikov` (Epanechnikov), `biweight` (Biweight), `triangular` (Triangular), `cosine` (Cosine), `uniform` (Uniform (box)) |
| Fixed Bandwidth (0 = rule) | `fixedBandwidth` | Number |
| Bounded Below | `useLower` | On / off |
| Lower Bound | `lower` | Number |
| Bounded Above | `useUpper` | On / off |
| Upper Bound | `upper` | Number |

### Statistic Lines (`statLines`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Mean Line | `showMean` | On / off |
| Median Line | `showMedian` | On / off |
| Percentile Lines | `percentiles` | Text |
| Computed For | `scope` | `all` (All data in the panel), `group` (Each group) |
| Labels | `showLabels` | On / off |
| Color | `color` | Colour |

### Reference Line (`reference`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Show Reference Line | `show` | On / off |
| Value | `value` | Number |
| Label | `label` | Text |
| Color | `color` | Colour |

### Value Axis (`valueAxis`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Show | `show` | On / off |
| Fixed Minimum | `useMin` | On / off |
| Minimum | `min` | Number |
| Fixed Maximum | `useMax` | On / off |
| Maximum | `max` | Number |
| Logarithmic Scale | `log` | On / off |
| Gridlines | `gridlines` | On / off |
| Show Title | `showTitle` | On / off |
| Title | `title` | Text |
| Decimal Places (-1 = auto) | `decimals` | Number |
| Font Size | `fontSize` | Number |
| Text Color | `color` | Colour |

### Group Axis (`categoryAxis`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Show | `show` | On / off |
| Show n per Group | `showN` | On / off |
| Font Size | `fontSize` | Number |
| Text Color | `color` | Colour |
| Show Title | `showTitle` | On / off |

### Data Labels (`labels`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Median | `showMedian` | On / off |
| Quartiles | `showQuartiles` | On / off |
| Mean | `showMean` | On / off |
| Font Size | `fontSize` | Number |

### Data Labels (`histLabels`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Bar Values | `show` | On / off |
| Font Size | `fontSize` | Number |

### Colors (`colors`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| One Colour for All Groups | `single` | On / off |
| Colour | `fill` | Colour |

### Legend (`legend`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Show | `show` | On / off |
| Position | `position` | `top` (Top), `bottom` (Bottom) |
| Font Size | `fontSize` | Number |
| Text Color | `color` | Colour |

### Smart Caption (`caption`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Show | `show` | On / off |
| Position | `position` | `top` (Top), `bottom` (Bottom) |
| Font Size | `fontSize` | Number |
| Text Color | `color` | Colour |

### Footnote (`footnote`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Show | `show` | On / off |
| Source | `source` | Text |
| State the Methods | `showMethod` | On / off |
| Font Size | `fontSize` | Number |
| Text Color | `color` | Colour |

### Theme (`theme`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Theme | `selectedTheme` | `smartvisuals` (SmartVisuals), `dark` (Dark), `clean` (Clean (White)), `slate` (Slate) |
| Font | `font` | `inter` (Inter), `segoe` (Segoe UI), `arial` (Arial), `georgia` (Georgia) |
| Transparent Background | `transparentBg` | On / off |

### Group Colors (`groupColors`)

| Setting | Internal name | Type or options |
| --- | --- | --- |
| Colour | `fill` | Colour |
