This file is indexed.

/usr/share/doc/grads/html/gradcomdsetdefval.html is in grads 2:2.0.1-1build1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
<!--Copyright (C) 1988-2005 by the Institute of Global Environment and Society (IGES). See file COPYRIGHT for more information.-->

<html>
<head>
<title>GrADS Command: set defval</title>
</head>
<body text="#000000" bgcolor="e0f0ff">

<h2><b>set defval</b></h2>

<p>
This command is used to interactively modify grid point values for
2-dimensional <a href="gradcomddefine.html"><code>defined</code></a>
variables. It is generally used in conjunction with <a
href="gradcomdquery.html"><code>query defval</code></a>. The syntax is:
<p>
<ul><code>set defval <i>var ival jval value</i></code></ul>

<p>
where:
<ul>
<code><i>var</i>&nbsp;&nbsp;&nbsp;&nbsp;</code>- the 2-D defined variable<br>
<code><i>ival</i>&nbsp;&nbsp;&nbsp;</code>- X coordinate of the grid point<br>
<code><i>jval</i>&nbsp;&nbsp;&nbsp;</code>- Y coordinate of the grid point<br>
<code><i>value</i>&nbsp;&nbsp;</code>- the new value for the variable, or &quot;missing&quot; to set variable as undefined<br>
</ul>

<p>
<h3>Usage Notes</h3>
<p>
<ol>
<li>A typical application of <code>set defval</code> might be to correct the value of an isolated bad data value discoverd through a maskout operation. 
</ol>

<p>
<h3>Examples </h3>

<p>'set defval var 8 22 missing' </p>
<p>Here is a sample script <a
href="ftp://grads.iges.org/grads/scripts/defval_demo.gs">defval_demo.gs</a>
  that illustrates the use of <code>query defval</code> and <code>set
    defval</code> commands.
</p>
<pre>
'open model.ctl'

* restrict the dimension environment to see things more clearly
xmin =  0.5
xmax = 15.5
ymin =  0.5
ymax = 10.5
'set x 'xmin' 'xmax
'set y 'ymin' 'ymax

* the "defval" commands will only work with 2-D defined variables 
'define var = ps'

* Display the variable with colored grid cells and their values
'c'
'set grid off'
'set mproj off'
'set xaxis 'xmin' 'xmax
'set yaxis 'ymin' 'ymax
'set gxout grfill'
'd var'
'set gxout grid'
'set digsiz .14'
'd var'

* Use the mouse to click on a grid point to change
say 'Click on any grid point'
'q pos'
xscreen = subwrd(result,3)
yscreen = subwrd(result,4)

* Convert screen positions to grid coordinates
'q xy2gr 'xscreen' 'yscreen
xgrid = subwrd(result,3)
ygrid = subwrd(result,6)

* Round the grid values to the nearest integer
gx = math_nint(xgrid)
gy = math_nint(ygrid)

* Get the value of the defined variable 
'q defval var 'gx' 'gy
val = subwrd(result,3)
say 'The value at grid point ('gx','gy') is --> 'val

* Ask for a new replacement value and assign it
prompt 'Enter a new value --> ' 
pull newval
'set defval var 'gx' 'gy' 'newval

* Display the newly updated variable
'c'
'set xaxis 'xmin' 'xmax
'set yaxis 'ymin' 'ymax
'set gxout grfill'
'd var'
'set gxout grid'
'd var'
</pre>

</body>
</html>