Navigation:  How do I ...? > Scaling >

How do I force scaling on the X axis to be equal to the scaling the Y axis?

Print this Topic Previous pageReturn to chapter overviewNext page

In other words, how do you set scale factors such that the physical distance for a given range between values on the X axis is the same as the physical distance for the same range in values on the Y axis?

For XY plots, DPlot initially uses as much of the display as possible for a plot. For this reason, the physical distance between equal values on the X and Y axes will generally not be the same. You can force a 1:1 scaling by using the Extents/Intervals/Size command on the Options menu.

For linear X and Y scales

Check both the Specify extents and Specify plot size boxes. Enter the desired extents on both the X and Y axes under Specify extents, then use proportional values for the plot width and height under Specify plot size. For example, if the X axis extends from 2 to 8 (10 units) and the Y axis extends from 4 to 8 (4 units), then the plot width should be 10/4 = 2.5 times the plot height. Conversely, if you want the plot width and height to be specific values (square, for example), then change the plot extents so that they are proportional to the width and height. For example, if the plot width and height are set to 6 and 4 inches, respectively, then the extents on the X axis should be 6/4=1.5 times the extents on the Y axis.

You can also have DPlot automatically adjust the plot extents for linear scales by, again, checking both the Specify extents and Specify plot size boxes, then clicking the Set X:Y=1:1 button. DPlot will decrease either the width or height of the plot to get the desired aspect ratio. Note that this setting is not persistent; if you subsequently change the extents or the size values or zoom in/out on a plot, the 1:1 relationship will not necessarily be maintained.

For logarithmic X and Y scales

If you do not care about the actual physical dimensions of the X and Y axes and want to allow DPlot to use the full extents of the display and/or printed page, simply check the Square Log Cycles item on the Options menu. You'll also need to ensure that Specify plot size on the Extents/Intervals/Size dialog is unchecked.

If you would rather specify the plot size, then the steps to take are similar to those for linear scales except that you will be comparing the logarithms of the axis extents rather than the displayed numbers. For example, if the specified plot extents are (1,1) to (1000,100), then the plot width should be (log(1000)-log(1))/(log(100)-log(1)) = 1.5 times the plot height. Conversely, if you want the plot width equal to the plot height, you can adjust the extents accordingly. In the previous example you could change the Y axis extents to 0.5 to 500 (or 1 to 1000 or 0.1 to 100, etc.) so that the range in logarithms is identical to the range in logarithms on the X axis.

For Mercator projections

DPlot will force the size of the plot to get the proper relationship between physical distances on the X and Y axes, regardless of whether you've used the Extents/Intervals/Size command to set the extents and/or size. But the changes it makes will not necessarily be desirable: the plot might be too wide or too high to suit your needs. For the best, most predictable results, as with linear and logarithmic scales use the Extents/Intervals/Size command, check both the Specify extents and Specify plot size boxes and enter the associated values, then click the Set X:Y=1:1 button.

 

 


Page url: https://www.dplot.com/help/index.htm?how_xyscaling.htm