【发布时间】:2019-03-10 04:14:38
【问题描述】:
所以,我有一个包含 3 列(和 40000 行)的文件,第一列是 x 坐标,第二列是 y 坐标,第三列是“多少”,我想从这个文件中生成等高线图。我四处搜索,并设法使其与another post 的解决方案一起工作。但最终结果的分辨率非常低: []
我尝试调整“set dgrid3d 100,100,4”这一行,但效果并不大。有什么帮助吗?最终结果应该是这样的:
编辑:我正在使用的代码
set contour
unset surface
set cntrparam levels incr 0.0,0.1,1.0
set view map
set xrange [0:30]
set yrange [0:30]
set dgrid3d 100,100,4
set table "contour.txt"
splot 'this.txt'
unset table
unset contour
set surface
set table "dgrid.txt"
splot 'this.txt'
unset table
reset
set pm3d map
unset key
set palette defined (0 '#352a87', 1 '#0363e1',2 '#1485d4', 3 '#06a7c6', 4 '#38b99e', 5 '#92bf73', 6 '#d9ba56', 7 '#fcce2e', 8 '#f9fb0e')
set autoscale fix
set grid
splot 'dgrid.txt' w pm3d, 'contour.txt' w l lc rgb "black"
【问题讨论】:
-
你有多少个数据点?也许你可以提供数据。您使用的确切代码是什么?
-
用我正在使用的代码更新了问题。数据数量不是问题,有40000个点