<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">
<div>Hi, Mano —&nbsp;</div>
<div>If you want to fill the area of the grid domain with a color of your choice, then you can do this:</div>
<div>‘set rgb 20 100 100 100 100’ &nbsp;;* a transparent grey</div>
<div>‘set ccolor 20’</div>
<div>‘d const(var,0)’</div>
<div><br>
</div>
<div>If you want to draw an outline, then here is an algorithm to try:</div>
<div>1. Draw a blank plot covering the largest domain to set up the scaling environment</div>
<div>2. Construct a ‘draw line’ command by looping over the grid coordinates at the boundaries (e.g. x=1,y=1:YDEF, y=1,x=1:XDEF, etc.) and using the 'q this2that’ commands (either 'q gr2xy’ or ‘q w2xy’) to get the location in X,Y space of each grid point.&nbsp;</div>
<div><br>
</div>
<div>cmd=‘draw line ‘</div>
<div>loop over edges</div>
<div>&nbsp; &nbsp;cmd=cmd%xpos’ ‘ypos’ '</div>
<div>endloop</div>
<div>cmd</div>
<div><br>
</div>
<div>—Jennifer</div>
<br>
<div>
<div>On Oct 15, 2016, at 10:41 AM, Jeff Duda &lt;<a href="mailto:jeffduda319@gmail.com">jeffduda319@gmail.com</a>&gt; wrote:</div>
<br class="Apple-interchange-newline">
<blockquote type="cite">
<div dir="ltr">
<div>
<div>
<div>
<div>
<div>
<div>
<div>
<div>There's no simple or easy way to do it. Here are two methods I have used in the past:<br>
<br>
</div>
1) Generate a netcdf grid using whatever library you're familiar with (if any). Make the grid the same size as your model domain. You can make the values inside the grid essentially whatever you want so long as you can bound the outer edge of the domain in
 a single contour. I suggest making all values in the domain either 0.0 or 1.0. Then write a control file to display that grid and make sure the value of UNDEF is set to something other than the value on the grid. Then just display the field using gxout contour
 and with contour labeling set to off.<br>
<br>
</div>
2) Use gxout fwrite and define any field on that domain using const like 'define field = const(tmp,1,-a)' which essentially does the same thing as in option 1, except it will write the field to a binary file instead of a netcdf file. Then you can just modify
 the control file you used for the original data set (assuming you used one), just changing the DSET, DTYPE, and VARS entries to suit your new data. Whatever the name of the field you wrote (in this example, it was defined using the name 'field'), the VARS
 entry will become<br>
</div>
VARS 1<br>
</div>
field 0 99 field<br>
</div>
ENDVARS<br>
<br>
</div>
Also make sure to set UNDEF to some value other than the constant value (1 in this example). Then, as in the first suggestion, display the field using gxout contour and with contour labeling off.<br>
<br>
</div>
Once you have the general idea here, you can manipulate the steps to make small alterations to improve the output image.<br>
<br>
</div>
Jeff Duda<br>
</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On Fri, Oct 14, 2016 at 7:59 PM, lpasmanoranjan <span dir="ltr">
&lt;<a href="mailto:lpasmanoranjan@gmail.com" target="_blank">lpasmanoranjan@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div class="gmail_quote">
<div dir="ltr">
<div class="gmail_quote">
<div dir="ltr">
<div>
<div>Dear GrADS users,<br>
</div>
I would like to ask you a favour.</div>
<div><br>
</div>
<div>I would like to highlight the following three model domains in one figure around my study region (India as center). But I can't able to draw the closed polygons as in the attachment.&nbsp;</div>
<div><br>
</div>
<div>I have three model domains in Lambert conformal conic projection:&nbsp;</div>
<div>MODEL 1: (8S,50E), (8S,90E), (45N,95E), (45N,45E).</div>
<div>MODEL 2: (7S,42E), (7S,92E), (47N,97E), (47N,41E).</div>
<div>MODEL 3:&nbsp;</div>
<div><br>
</div>
<div>Would you please suggest how to do it in grads!!</div>
<div><br>
</div>
<div>Thank you very much for any kind of help or suggestion.</div>
</div>
</div>
</div>
</div>
<span class="HOEnZb"><font color="#888888"></font></span></div>
<span class="HOEnZb"><font color="#888888"><br>
<br>
-- <br>
<div dir="ltr">
<div>Kind Regards,<br>
</div>
Mano<br>
</div>
<br>
</font></span><br>
______________________________<wbr>_________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
<a href="http://gradsusr.org/mailman/listinfo/gradsusr" rel="noreferrer" target="_blank">http://gradsusr.org/mailman/<wbr>listinfo/gradsusr</a><br>
<br>
</blockquote>
</div>
<br>
<br clear="all">
<br>
-- <br>
<div class="gmail_signature" data-smartmail="gmail_signature">
<div dir="ltr">Jeff Duda<br>
Post-doctoral research associate<br>
University of Oklahoma School of Meteorology<br>
</div>
</div>
</div>
_______________________________________________<br>
gradsusr mailing list<br>
<a href="mailto:gradsusr@gradsusr.org">gradsusr@gradsusr.org</a><br>
http://gradsusr.org/mailman/listinfo/gradsusr<br>
</blockquote>
</div>
<br>
<div apple-content-edited="true">
<div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">
<div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">
<div style="font-size: 12px; orphans: 2; widows: 2;">--</div>
<div style="font-size: 12px; orphans: 2; widows: 2;">Jennifer Miletta Adams<br>
Center for Ocean-Land-Atmosphere Studies (COLA)<br>
George Mason University<br>
<br>
<br>
</div>
</div>
</div>
</div>
<br>
</body>
</html>