1.191 FAQ-892 How to plot evenly spaced column/bar for unevenly spaced numeric X?

Last Update: 2/18/2019


We recommend Origin 2018 for this since it directly plots so for multi-Y data.

Show As Evenly Spaced Bar.png

If plotting single Y data or using older Origin versions before Origin 2018, X are not evenly spaced. there are four approaches.

Approach 1: Set X as Text before Plotting
  1. Double click X column header to open the Column Properties dialog. Set Format as Text under Options branch
    Show As Evenly Spaced Bar 10.png
  2. Plot column/bar graph.

!!!Drawback: Since the X column is changed to text, you will not be able to use it as numeric data for subsequent analysis such as curve fitting.

Approach 2: Use Plot Setup Dialog to Plot against Row Index
  1. Without any column selected in worksheet, select Plot > Basic 2D : Column menu to open Plot Setup dialog. In the middle panel, select <autoX> as X, and check col(B) as Y. Click Add button and then OK button to plot a column/bar graph.
    Show As Evenly Spaced Bar 07.png
  2. The tick labels will show 1, 2, 3, ... To show X values as tick labels, double click the X tick label to open the Axis dialog. On Tick Labels main tab, go to Display sub-tab, set Type to Text from dataset and select column A as Dataset.
    Show As Evenly Spaced Bar 06.png
Approach 3: Set X column as Disregard or Y column before Plotting

By default when user highlights some Y column(s) to plot, Origin will auto-find X column on the left and plot against it. If there is no X column on the left, then Origin will plot against row index.

  1. Right click X column header and select Set As: Disregard or Set As: Y from the context menu.
    Show As Evenly Spaced Bar 05.png
  2. Highlight column B to plot the column/bar graph.
  3. Same as Approach 2, the X tick labels is 1, 2, 3... by default. Double-click on any X tick label axis to open the Axis dialog. On Tick Labels tab, go to the Display sub-tab, set Type to Text from dataset and select column A as Dataset.
    Show As Evenly Spaced Bar 06.png

!!!Drawback: Since X column is set as disregard/Y column, when doing analysis, Origin will not find X column by default either.

Approach 4: Set Axis Type as Discrete
  1. If the graph is already created, double click on X axis to open the Axis dialog. On Scale tab, set Type to Discrete as below. Click Apply button.
    Show As Evenly Spaced Bar 04.png
  2. Now, the columns/bars are distributing evenly spaced. To make show X data as tick labels,
    Still on Scale tab, go to Major Ticks branch to specify X data as tick positions:
    Show As Evenly Spaced Bar 08.png
    OR
    Go to Tick Labels tab, in the Display sub-tab, set Tick Labels Type as Tick-indexed Dataset, and show X data as tick labels.
    Show As Evenly Spaced Bar 09.png

Keywords:unevenly spaced, column, bar, evenly spaceD, equally spaced, isometric, discrete