Origin has a layer level option linking axis length to its scale so that axis will have the same unit length. This post will help you to go one step further, because in categorical data, we only want to link one of the axis (Y axis) to its scale, while keep X as it is for it’s just categories.
If you want to walk through the steps with me, please download this sample data.
The raw data shows as below:
Highlight all four columns and plot a column graph. You can finish most of the customization since Origin’s batch plotting can duplicate the graph with new data. Here are some important changes that you need to make:
- Open the Axis Dialog for Y axis and set its Rescale mode to Auto.so that when new data be used, the Y axis range can be adjusted accordingly.
- Hide the X axis tick and labels because only one of the three graphs needs it.
- Right click in white area and choose Add/Modify Layer Title and enter %(1Y, @WS). Right click it and choose Properties and click on the Programming tab. Set Link to (%,$), Substitution Level to 1. This will convert the subsitution notation %(1Y, @WS) into sheet name.
- In Plot Details dialog, choose Layer1 on left panel, go to Size tab and change Scale Elements to be Fixed Factor with value 1 so that everything will not be scaled with layer size changing.
- Right click graph window title and select Duplicate (Batch Plotting), set Batch Plot with = Sheet. Select the other two sheets and click OK.
- Update the color for the duplicated graphs first since they uses the same color setting as the first one.
- Go to menu Graph: Merge Graph Windows and set it as a 3*1 layout. Check Set Layer Height by Common Scale checkbox so that each layer height will adjust proportionally based on the range of axis.
- However, from the preview we see that the Test-1 layer is on the top instead of bottom. That’s because this tool by default place the graphs based on the list in Graphs. Use the Move Up/Move Down buttons beside Graphs to arrange windows in the order Graph7, Graph6, Graph 5, then click the OK button.
- Turn the X axis tick and label back on the bottom axis. You will got your graph as below:
You can look at the expected graph under Result folder in the opj you downloaded.
One Comment on “Make Stacked Graph with Same Axis Unit Length”