Hi all,
I recently updated to gmt 6.2.0 from 6.1.0 and am having trouble with one of the updates to sample1d. Originally, if I had a look-up table (lookup.xy) like this:
0 00
1 10
2 20
And sampled it at these points (sample.x):
0.5
1.5
1.9
1.5
Using “gmt sample1d -Fl -Tsample.x lookup.xy” would return:
0.5 5
1.5 15
1.9 19
1.5 15
But the updated version gives:
sample1d [WARNING]: Eliminated 1 duplicate values from the sorted array
0.5 5
1.5 15
1.9 19
I understand from this thread (Sample1d on gmt6.1 and gmt6.2) why this update was made, but is there a way to not skip the duplicates? Often I am stripping columns from a data file, using sample1d to find a corresponding value, and pasting things back together, which now doesn’t work when there happen to be duplicate values due to the rows no longer corresponding. Or am I using the wrong tool for the job?
Also, has a sorting procedure been added, such that the points are not necessarily returned in their original order?
Thanks a lot for your help!