0

I've been a longtime user of xmgrace/grace, but today I'm stumped. I have a .dat file that is simply two columns of space-separated X Y data like I'm accustomed to plotting. But for some reason the program is only using the Y information and plotting X as the integer sequence/row numbers. Here's a sample of the data:

$ cat test.dat
0.016426149 0.91780442
0.016559154 1.942617893
0.016692159 1.937870622
0.016758662 2.160227537
0.016825165 1.464688301
0.016891667 2.413390636
0.017024672 2.62378788
0.017024672 2.396263838
0.01722418 2.30436182

but when I run xmgrace test.dat (or try Data > Import > ASCII...), the x-axis goes from 0 to 14 instead of 0.0164 to 0.0172. I don't see any hidden characters in the file (used :set list in vi)...

If this helps: The file was originally a CSV that I exported from Excel on my Mac, and used vi to replace the commas with spaces. So...there are no tabs in the file, and no Windows-style ^M's.

How do I get xmgrace to use my x information properly?

sh37211
  • 1,411
  • 1
  • 17
  • 39
  • I can't reproduce your issue. Does this happen only with that file? What if you try to copy&paste the data in another file? – lr1985 Sep 28 '21 at 10:21
  • @lr1985 Thanks for your reply. That test.dat example was a copy & paste from a longer file. Interestingly if I copy & paste those numbers from this website, then it plots no problem! This suggested that I paste into an online "special character stripper", which after that I could plot as normal. And yet vi didn't show any special characters. Very odd! – sh37211 Sep 29 '21 at 15:54
  • This is bizarre indeed, although unicode is a weird beast! – lr1985 Oct 03 '21 at 14:01

0 Answers0