I have some data (32 points) which corresponds to elements along an artificial transmission line of a fixed distance. The plot in its current form is shown below:

ListLinePlot of data

What I am trying to do is make the numbers along the horizontal axis map to a range of [0,1] instead of [0,32]. Since the spacing between the data points cannot be changed, I was wondering how I might go about changing the Tick marks.

Thank you

  • 1
    $\begingroup$ Welcome to Mathematica.SE! I suggest the following: 0) Browse the common pitfalls question 1) As you receive help, try to give it too, by answering questions in your area of expertise. 2) Read the faq! 3) When you see good questions and answers, vote them up by clicking the gray triangles, because the credibility of the system is based on the reputation gained by users sharing their knowledge. Also, please remember to accept the answer, if any, that solves your problem, by clicking the checkmark sign! $\endgroup$ – Dr. belisarius Sep 13 '15 at 0:35
  • $\begingroup$ Look at the examples given under Examples > Options > DataRange in the documentation article on ListPlot $\endgroup$ – m_goldberg Sep 13 '15 at 1:21
  • $\begingroup$ Or provide the data as {x,y} pairs. $\endgroup$ – Sjoerd C. de Vries Sep 13 '15 at 8:07
data = Sin[Pi/32 Range@32]
ListPlot[data, DataRange -> {0, 1}]

Mathematica graphics

  • $\begingroup$ Thank you for this answer, it resolved my issue. $\endgroup$ – Patrick Harrington Sep 13 '15 at 2:59

Not the answer you're looking for? Browse other questions tagged or ask your own question.