number of digits on ticks
I am not able to get a consistent number of digits on the x-axis of the following plot (as example), where I want exactly one digit after the decimal point, i.e. I want "4.0" instead of "4". This is caused by "zapTZ = 1", but in the default setting (=0) I will end up with an extra digit on all values which I don't want.
Did I miss something?
macro Graph0()
// make data
make/O/N=4 w=0.365
setscale/i x 3.7,4.1, w
Display /W=(98,94,579,486) w
ModifyGraph tick=2
ModifyGraph mirror=1
ModifyGraph fSize=25
ModifyGraph zapTZ(bottom)=1
SetAxis/N=1 left 0.339,0.391
SetAxis/N=1 bottom 3.75,4.12
EndMacro
*********** EDIT ***************
Adjusting the number of ticks solved the problem, i.e.
ModifyGraph nticks(bottom)=4,zapTZ=0
Another way to do it is to use "Computed manual ticks"
In the Modify Axis dialog, Auto/Man Ticks tab:
Select Computed Manual Ticks from the menu in the upper left corner of the tab.
Set the Tick Increment to 0.1
Set Digits After Decimal Point to 1
If you want the minor ticks as in your first attempt, under Minor Ticks set Number Per Major Tick to 1.
May 14, 2025 at 11:16 am - Permalink