0
$\begingroup$

I would like to have a custom ticks on x-axis on my ListPlot, but nothing is showing, what am I doing wrong?

data = {{1, 2}, {2, -2}, {3, -1}, {4, 0}, {5, -3},
 {6, -2}, {7, -1}, {8, -1}, {9, -1}, {10, 0}};

ListPlot[data, 
 FrameTicks -> {{"ττ", "τr", "τθ", 
    "\τφ", "rr", "rθ", "rφ", 
    "θθ", "θφ", 
    "φφ"}, {-5, 5}}, Frame -> True, 
 PlotMarkers -> {Automatic, Medium}, Axes -> False,ImageSize -> 500]

And I get

enter image description here

$\endgroup$
8
  • $\begingroup$ Why do you think this will work. Have you looked at FrameTicks and Ticks documentation? Especially Details section is going to be helpful. $\endgroup$
    – Kuba
    Commented Sep 23, 2013 at 14:04
  • $\begingroup$ So I cannot put any custom ticks in Mathematica? Well that sucks :( $\endgroup$
    – dingo_d
    Commented Sep 23, 2013 at 14:12
  • $\begingroup$ @dingo_d Of course you can; Kuba is saying that you don't have the correct syntax. Please see the answer to the question I just closed this as a duplicate of. Also re-read the documentation for Ticks and FrameTicks. $\endgroup$
    – Mr.Wizard
    Commented Sep 23, 2013 at 14:14
  • $\begingroup$ I had an answer with you that solved this particular problem but the duplicate will do just as well. Here's a start: labels = {"\[Tau]\[Tau]", "\[Tau]r", "\[Tau]\[Theta]", "\[Tau]\[CurlyPhi]", "rr", "r\[Theta]", "r\[CurlyPhi]", "\[Theta]\[Theta]", "\[Theta]\[CurlyPhi]", "\[CurlyPhi]\[CurlyPhi]"}; ticks = Table[x, {x, 0, 9}]; frameticks = Transpose[{ticks, labels}] then set the option FrameTicks -> {{False, False}, {frameticks, False}} $\endgroup$
    – C. E.
    Commented Sep 23, 2013 at 14:15
  • 1
    $\begingroup$ @dingo_d In FramTicks details: "For each edge, tick marks can be specified as described in the notes for Ticks.". And as it is written, in Ticks documentation there are examples how the proper syntax with labels looks. $\endgroup$
    – Kuba
    Commented Sep 23, 2013 at 14:21

0

Browse other questions tagged or ask your own question.