Is it possible to have two sets of labels for the $x$-axis tick marks using ListPlot
? For example, could we have tick marks labels: {1,2,3,4,...}, and then right below these labels, the values for the powers of two: {2,4,8,16,...}?
1 Answer
$\begingroup$
$\endgroup$
1
A starting point :
data = Table[{i, i + 1}, {i, 10}];
ListPlot[data, Ticks -> {Table[{i, Column[{i, Style[2^i, Red]}]}, {i, 10}], Automatic}]
-
$\begingroup$ But what to do if I need a frame and grid lines! Setting Frame -> True kills custom labeling (reference.wolfram.com/language/tutorial/…). Nevermind, just found an answer: mathematica.stackexchange.com/questions/32831/… $\endgroup$ Feb 12, 2016 at 0:21