# Algorithm vs guidelines for choosing axes divisions when graphing data

A central skill in maths is graphing a set of data on a pair of axes with premarked divisions. Whether the axes are prelabeled with appropriate numbers or not changes the difficulty of this task a lot. I'd like to focus on making an appropriate labelling with numbers of the axes. (Of course, this is a 2d version of labelling and marking numbers on a number line.)

I consider this the most difficult task asked of high school students. For want of an algorithm I find myself offering vague rules of thumb, eg

• count the number of horizontal and vertical divisions
• find the range(s) of your (rounded) data
• try to fit these ranges onto your axes
• try assigning numbers to your divisions going up in 1s, 2s, 4s and 5s, (or 0.1, 0.2, ... 10,20, ..., etc) see https://en.m.wikipedia.org/wiki/Preferred_number#1-2-5_series
• proceed by trial and error, erasing when necessary
• try to use as much available of the graph paper as possible.

Question: What is an algorithm for doing this task?

(apologies for the terminology used in this question, divisions vs labelling. Are they tick marks?)

• Hmm, I think I'm having difficulties to understand the point of the question. What are you trying to achieve with such an algorithm? Oct 6, 2022 at 12:16
• Humans don't learn through algorithms. Yes, this is a difficult task for students. No, don't try to remove the difficulty. Work together, talk it through. Oct 6, 2022 at 17:53
• Out of curiosity, is this for a particular course? I teach curve sketching in calculus where we go through items in a checklist, but this seems a quite a little different. Oct 7, 2022 at 21:27
• (The OP says data, so I guessed statistics.) Oct 8, 2022 at 3:10

What has to be understood by the students is that the particular way of labeling the axis (including not labeling them at all) should be chosen based on what function features you want to emphasize with your graph. For instance

1. You want to convey the message that $$f(x)$$ is positive everywhere. Then having the horizontal axis on the graph is more than enough and the rest is pure noise.

2. You want to emphasize that $$f$$ is defined on $$[-1,3]\cup[5,6]$$ and maps those intervals into $$[0,1]$$ and $$[6,7]$$ respectively. Then marking $$-1,3,5,6$$ on the $$x$$-axis and $$0,1,6,7$$ on the $$y$$ axis is what you want.

3. You want to see the detailed behavior of $$f(x)=x^2$$ near the point $$x=100$$. Then you choose the bounding box $$[98,102]\times [9600,10500]$$, say with 10 equally spaced ticks in each (or equally spaced $$x$$-ticks and marked values of $$f(x)$$ at them on the $$y$$-axis

4. You want to show that $$f(x)=10000+x^2$$ is huge on $$[0,1]$$. Draw the horizontal axis through $$0$$ and mark the $$y$$-scale in thousands.

5. You want to show that the same function doesn't change much on $$[0,1]$$. Draw the horizontal axis at $$y=10000$$ and label $$y$$-axis in $$0.1$$-s.

And so on, and so forth. We draw a graph of a function to quickly tell a story about it, not just to exercise in connecting dots by a smooth line (though the latter skill requires some training as well). So, before choosing the scales and the bounding box, ask yourself "What story do I want to tell and what is the clearest way in which I can do it?". Or, when looking at the graph, ask "What are the features of the function I see immediately from that drawing and what are the features that would be hard to discern from it?". It is like choosing words in a sentence. There is a big difference between "I took a walk", "I took a long walk in a beautiful Fall forest", "I took a 7 mile walk on a hilly terrain with average inclination 5%" and "I took a 3 hour walk despite the fact that I should rather spend that time preparing my classes" while they all can describe the same full reality "I took a 3 hour walk of total length 7 miles (which I consider long) in a beautiful Fall forest located on a hilly terrain with average inclination 5%, though I should rather spend that time preparing my classes". The same applies to mathematical communication and, in particular, to mathematical communication using pictures. The real objective is to say exactly as much as you want to say in the clearest possible manner. Alas, as far as I know, there are no ready algorithms for that either in mathematics on in the natural language.