爱气象,爱气象家园! 

气象家园

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博登陆

只需一步, 快速开始

搜索
查看: 7873|回复: 11

[图形美化] Grads画中国地图总是有省界

[复制链接]

新浪微博达人勋

发表于 2017-4-15 22:06:59 | 显示全部楼层 |阅读模式

登录后查看更多精彩内容~

您需要 登录 才可以下载或查看,没有帐号?立即注册 新浪微博登陆

x
本帖最后由 aridlhy 于 2017-4-15 22:21 编辑

想做一张世界地图背景下的中国区域的图片,但是无论怎么做都会有省界的存在,不知有没有遇到类似情况的,也不知怎么解决了贴出gs文件。 QQ截图20170415221146.png

    'reinit'
  'set vpage 0 11 0 8.5'
  'set grads off'
  'set grid off'
    m=1
  while(m<=3)
  y0=1.825*(5-m-1)+0.7
  y1=1.825*(5-m-1)+2.325
    n=1
    while(n<=3)
    x0=3.1*(n-1)+1
    x1=3.1*(n-1)+3.8
    name=m+4  
    'open D:\revision_flux_evaluation\mean_std\dat\'%name%'-sea.ctl'
    'open D:\revision_flux_evaluation\mean_std\dat\'%name%'-yr.ctl'
    'set grads off'
    'set grid off'
    'set mpdset cn'
    'set parea 'x0' 'x1' 'y0' 'y1   
    'set lon 70 140'
    'set lat 15 55'
    'set xlab off'   
    'set xlevs 80 100 120 140'
    'set xlopts 1 4 0.12'
    if(m=3)
    'set xlab on'  
    else
    'set xlab off'
    endif
    if(n=1)
    'set ylab on'  
    else
    'set ylab off'
    endif
    'set ylevs  15 30 45'
    'set ylopts 1 4 0.12'   
    'set gxout shaded'

*    'run define_colors.gs'   
    if(n=1)
      'set clevs -10 0 10 20 30 40 60 80 100'
      'set ccols 47 45 44 35 33 31 23 25 27 29'
      'cnbasemap hs_sum'
    endif
    if(n=2)
      'set clevs -10 0 10 20 30 40 60 80 100'
      'set ccols 47 45 44 35 33 31 23 25 27 29'
      'cnbasemap hs_win'
    endif
    if(n=3)
      'set clevs -10 0 10 20 30 40 60 80 100'
     'set ccols 47 45 44 35 33 31 23 25 27 29'
      'cnbasemap hs.2'
    endif
    if(m=3&n=3);'cbar_v2  0 5.5 1.8 7.0 0.2 0.20';endif
    if(m=3&n=3);'draw string 9.5 1.8  Wm`a-2`n';endif   
    'set font 4'
    'set string 1 c 3 90'
    'set strsiz 0.2'
    if(m=1&n=1);'draw string 'x0-0.7' 'y0+(y1-y0)/2' CLM';endif   
    if(m=2&n=1);'draw string 'x0-0.7' 'y0+(y1-y0)/2' NOAH';endif   
    if(m=3&n=1);'draw string 'x0-0.7' 'y0+(y1-y0)/2' MOS';endif   
    'set string 1 c 3 0'
*    'southsea'      
    'close 2'
    'close 1'
    n=n+1
    endwhile
    m=m+1
  endwhile
  'enable print D:\revision_flux_evaluation\mean_std\hs-mean\2-test_v2.gmf'
   'print'
  'disable print'  



评分

参与人数 1金钱 +10 贡献 +2 收起 理由
river + 10 + 2 赞一个!

查看全部评分

密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2017-4-15 23:07:37 | 显示全部楼层
感谢分享,很棒啊,一页多图,统一色标,设置字符串等等都用到了,值得学习!
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2017-4-16 09:49:40 | 显示全部楼层
图很棒很漂亮{:5_213:}
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2017-4-16 10:17:44 | 显示全部楼层
图很棒很漂亮
密码修改失败请联系微信:mofangbao

新浪微博达人勋

 楼主| 发表于 2017-4-17 12:15:41 | 显示全部楼层
river 发表于 2017-4-15 23:07
感谢分享,很棒啊,一页多图,统一色标,设置字符串等等都用到了,值得学习!

gs文件随便拿去,知道问题解决方案吗
密码修改失败请联系微信:mofangbao

新浪微博达人勋

 楼主| 发表于 2017-4-17 12:16:03 | 显示全部楼层

gs文件随便拿去,知道问题解决方案吗
密码修改失败请联系微信:mofangbao

新浪微博达人勋

 楼主| 发表于 2017-4-17 12:16:10 | 显示全部楼层

gs文件随便拿去,知道问题解决方案吗
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2017-4-18 22:16:59 | 显示全部楼层
aridlhy 发表于 2017-4-17 12:15
gs文件随便拿去,知道问题解决方案吗

把省界关掉
set poli

set poli on|off

Selects whether you want political boundries drawn for the mres or hires map data sets. The default is on.

Settings stay the same until changed by new set commands.

或者试试把地图的分辨率调低试试,
set mpdset

set mpdset <lowres|mres|hires|nmap>

lowres is the default. mres and hires have state and country outlines. nmap covers only North America.

Settings stay the same until changed by new set commands.
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2017-4-22 16:58:25 | 显示全部楼层
请问怎么把中国地形叠加上去的我做的中国区域的,但是只有海岸线
密码修改失败请联系微信:mofangbao

新浪微博达人勋

发表于 2017-8-11 20:37:52 | 显示全部楼层
有图有程序,{:eb502:}{:eb502:}
密码修改失败请联系微信:mofangbao
您需要登录后才可以回帖 登录 | 立即注册 新浪微博登陆

本版积分规则

Copyright ©2011-2014 bbs.06climate.com All Rights Reserved.  Powered by Discuz! (京ICP-10201084)

本站信息均由会员发表,不代表气象家园立场,禁止在本站发表与国家法律相抵触言论

快速回复 返回顶部 返回列表