Graphs

Graphs menu. ChakataStat draws charts straight into the Output log, next to your tables. There are seven quick chart dialogs plus a free-form Chart Builder, and several analyses can attach their own plots.

The quick charts

Histogram

Graphs → Histogram… (Ctrl+Shift+H). Pick one scale variable to see the shape of its distribution — the spread, skew and any outliers. An optional normal curve overlay helps judge normality by eye.

Example. A histogram of BMI shows whether the sample is centred around a healthy range or skewed.

The bins control changes the display only — no data changes. To turn a scale variable into real analysis groups, use a Recode instead.

Bin labels chooses how the bars are labelled on the x axis: Edges (a plain tick at each bin boundary, the default), Range (each bar's interval, e.g. 11 – 20 — the same wording as Bin Variable's groups for the same cutpoints, so the two never disagree), Bar start (the value each bar starts at), or Custom (start + width) — set the leftmost bar's label range minimum and a fixed range width, and the rest of the bars' labels are computed from those two numbers, shown as clean, non-overlapping brackets (10 – 19, 20 – 29, 30 – 39, …) when both are whole numbers. This is a relabelling only: it doesn't change how the bars themselves are computed, so use it to lay your own numbering (e.g. age brackets) over bars whose actual computed edges are inconvenient floating-point values.

Every bar gets its own label under Custom (unlike the other modes, which thin to roughly 8 labels to avoid crowding a wide bin count) — the point of a hand-chosen numbering is a complete set of brackets. Label every is a dropdown that overrides either default — Auto, Every bar, or every 2nd/3rd/4th/5th/10th bar — if a high bin count still gets crowded.

Scatterplot

Graphs → Scatterplot… (Ctrl+Shift+T). Pick an X and a Y scale variable to see how two variables relate — the visual companion to a correlation.

Example. BMI (X) against SystolicBP (Y) — does blood pressure rise with BMI?

Boxplot

Graphs → Boxplot… (Ctrl+Shift+B). Summarise a scale variable's median, quartiles and outliers, optionally split by a categorical variable to compare groups side by side.

Example. SystolicBP boxed by SmokingStatus.

Line Chart

Graphs → Line Chart… (Ctrl+Shift+L). Plot one or more scale variables against an X variable (or case order, when none is given), optionally split by a categorical variable to compare one line per group. Turn on point markers to see the individual data points along each line.

Example. SystolicBP against Age, split by SmokingStatus — does the age trend differ across smoking groups?

Bar Chart

Graphs → Bar Chart…. Pick a category variable to chart the count of cases per level, or switch Bars show to the mean, sum or median of a scale variable per level. An optional Cluster by category groups bars side by side (one color per cluster level, with a legend), or — with Stacked bars ticked — stacks those segments into one bar per level (part-to-whole). Value labels drive the category axis, so a 1/2 coded variable labelled Male/Female charts by its labels.

Example. The mean SystolicBP by SmokingStatus, clustered by Sex.

Error Bar

Graphs → Error Bar…. The mean of a scale variable per level of a category, each mean with an error bar: a confidence interval of the mean (default 95%), or ± standard error / ± standard deviation with a multiplier of your choice. A second Cluster by category turns it into the classic interaction/profile plot — one connected point-run per level — the picture to check alongside a two-way ANOVA.

Example. Mean SystolicBP by SmokingStatus with 95% CIs; cluster by Sex to see whether the smoking effect differs between the sexes.

Q-Q Plot

Graphs → Q-Q Plot…. The standard visual normality check: a scale variable's sorted values against the quantiles of a theoretical distribution (normal by default, or Student t / chi-square at a chosen df), with a reference line fitted through the quartiles. Points hugging the line mean the distribution fits; systematic bowing means skew, S-shapes mean heavy or light tails. The formal companion tests live under Tests of Normality.

Example. A Q-Q plot of BMI before deciding between a t test and a Mann-Whitney.

Styling a chart

The Line Chart dialog's collapsed Style section controls presentation without touching the data: Legend placement (Auto/Right/Bottom/Hidden), a Line width stepper, and, when there is no split (so the series are known up front), a color swatch per series. Because these are options on the journaled command rather than a post-hoc chart editor, they show up in the .cks syntax too and reproduce exactly on re-run:

line_chart y=[SystolicBP], x=Age, legend=bottom, colors=["#1f77b4"], line_width=2.5

Example. colors=["#1f77b4"] keeps the first series' color fixed across re-runs even if the underlying palette rotation ever changes.

The Chart Builder

Graphs → Chart Builder… (Ctrl+Shift+G) is the general dialog: choose the chart type and assign variables to its roles. Use it when you want more control than the three quick dialogs give.

Charts attached to analyses

Some analyses can draw a chart built directly from their own result — look for a Plot… checkbox in the dialog. These include:

  • the Kaplan-Meier survival curve (and cumulative-hazard curve), with an optional Show point markers checkbox at each step;
  • the ACF/PACF correlogram from Autocorrelation;
  • the ARIMA forecast plot (observed, forecast and prediction band);
  • the canonical discriminant scatter (optionally with a territorial map);
  • the scree plot from Factor Analysis (eigenvalues per component, with the Kaiser criterion line at 1 — on by default);
  • the forest plot and funnel plot from Meta-Analysis (per-study effects with the pooled diamond; effect against precision with the pseudo-CI funnel — both on by default);
  • the dendrogram from Hierarchical Cluster (the merge tree from the agglomeration schedule — on by default; a very wide tree is rendered as its last merges, with collapsed clusters sized in parentheses and a note saying so).

See the relevant analysis pages for each.

Working with chart output

  • Charts appear as cards in the Output View, interleaved with tables in the order you ran them.
  • The output chart width is a setting — see Settings.
  • Charts are included when you export the output log to HTML/Markdown/LaTeX (rendered as their geometry) — see Reproducibility.