[GRASS-dev] missing help for r.cats

I just noticed that we are missing the help file for r.cats.

Michael


Michael Barton, Professor

Professor of Anthropology
Director of Graduate Studies
School of Human Diversity & Social Change
Center for Social Dynamics & Complexity

Arizona State University

Tempe, AZ 85287-2402

USA

voice: 480-965-6262; fax: 480-965-7671

www: http://www.public.asu.edu/~cmbarton

The file was renamed to r.category... r.cats as module
is there for backwards compatibility (so it should indeed have
a link to the help page).

Additionally, several manual pages refer to the old name:

GRASS 6.3.svn (pat):~/grass63/dist.x86_64-unknown-linux-gnu/docs/html

grep r.cats *

r.buffer.html:<B>r.cats input=</B>roads.buf
r.li.patchdensity.html:r.cats landcover.30m
r.report.html:<DD>Report for cats fp ranges (fp maps only)</DD>
r.statistics.html:r.cats elevstats
r.statistics.html:<A HREF="r.cats">r.cats</A>
r.stats.html:<DD>Report for cats fp ranges (fp maps only)</DD>
v.net.iso.html:# specify range of center cats (easier to catch all):
v.to.rast.html:r.cats myfields

Markus

On Feb 19, 2008 8:25 PM, Michael Barton <michael.barton@asu.edu> wrote:

I just noticed that we are missing the help file for r.cats.

Michael

______________________________

Michael Barton, Professor
Professor of Anthropology
Director of Graduate Studies
School of Human Diversity & Social Change
Center for Social Dynamics & Complexity

Arizona State University

Tempe, AZ 85287-2402

USA

voice: 480-965-6262; fax: 480-965-7671

www: http://www.public.asu.edu/~cmbarton

_______________________________________________
grass-dev mailing list
grass-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-dev

--
Open Source Geospatial Foundation
http://www.osgeo.org/
http://www.grassbook.org/

Markus Neteler <neteler@osgeo.org> writes:

> The file was renamed to r.category... r.cats as module is there for
> backwards compatibility (so it should indeed have a link to the
> help page).

> Additionally, several manual pages refer to the old name:

> $ grep r.cats *

  Please note that this searches for ``r'', any character,
  ``cats'', not for ``r'', period, ``cats''. Hence, the list
  below has three false positives.

  The proper command to search for the latter (assuming POSIX
  `grep' [1]) is:

$ grep -F r.cats *

> r.buffer.html:<B>r.cats input=</B>roads.buf
> r.li.patchdensity.html:r.cats landcover.30m
> r.report.html:<DD>Report for cats fp ranges (fp maps only)</DD>
> r.statistics.html:r.cats elevstats
> r.statistics.html:<A HREF="r.cats">r.cats</A>
> r.stats.html:<DD>Report for cats fp ranges (fp maps only)</DD>
> v.net.iso.html:# specify range of center cats (easier to catch all):
> v.to.rast.html:r.cats myfields

[1] http://www.opengroup.org/onlinepubs/009695399/utilities/grep.html

Markus writes:

> The file was renamed to r.category... r.cats as module is there
> for backwards compatibility

....

> Additionally, several manual pages refer to the old name:
> $ grep r.cats *

Ivan wrote:

  Please note that this searches for ``r'', any character,
  ``cats'', not for ``r'', period, ``cats''. Hence, the list
  below has three false positives.

  The proper command to search for the latter (assuming POSIX
  `grep' [1]) is:

$ grep -F r.cats *

Right. FWIW my method was 'grep -rI r\.cats *', but whatever route it
all gets to the same destination I guess...

I should have updated all of those when I renamed r.cats, oops. Done
now, all help page and GUI menu entries are updated in SVN/trunk, and
Markus has backported to the 6.3.0 branch.

r.category expands on the old r.cats as it can manage raster category
labels, whilst r.cats could only report them. There are interesting
things to play with like dynamic label names. It's very old library
functionality that has been somewhat hidden from the user for years.

Hamish

      ____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping

Hamish wrote:

> The proper command to search for the latter (assuming POSIX
> `grep' [1]) is:
>
> $ grep -F r.cats *

Right. FWIW my method was 'grep -rI r\.cats *'

If you're doing that from the shell, it needs two backslashes:

  grep -rI r\\.cats *

or quotes:

  grep -rI 'r\.cats' *

so that grep actually "sees" a backslash.

Or just use "grep -F" or "fgrep" for searching for fixed strings.

--
Glynn Clements <glynn@gclements.plus.com>

Glynn Clements <glynn@gclements.plus.com> writes:

>>> The proper command to search for the latter (assuming POSIX `grep'
>>> [1]) is:

>>> $ grep -F r.cats *

>> Right. FWIW my method was 'grep -rI r\.cats *'

> If you're doing that from the shell, it needs two backslashes:

> grep -rI r\\.cats *

> or quotes:

> grep -rI 'r\.cats' *

> so that grep actually "sees" a backslash.

> Or just use "grep -F" or "fgrep" for searching for fixed strings.

  And since one cannot reliably and portably quote a string into a
  regular expression in Shell, one has to use:

$ grep -F -- "$string" ...

  to search for a user-supplied string in a Shell script.

  (The `--' ``option'' prevents `"$string"' from being processed
  as an option even if it begins with `-'; consider, e. g.: `$
  grep -l *' vs. `$ grep -- -l *'.)

Glynn Clements wrote:

If you're doing that from the shell, it needs two backslashes:

  grep -rI r\\.cats *

or quotes:

  grep -rI 'r\.cats' *

so that grep actually "sees" a backslash.

Or just use "grep -F" or "fgrep" for searching for fixed strings.

true. another annoying flase positive thing since the move to SVN is
that duplicate '/.svn/' entries pop up and must be filtered out with
'grep -v'.

Hamish

      ____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping

Hamish <hamish_b@yahoo.com> writes:

>> If you're doing that from the shell, it needs two backslashes:

>> grep -rI r\\.cats *

>> or quotes:

>> grep -rI 'r\.cats' *

>> so that grep actually "sees" a backslash.

>> Or just use "grep -F" or "fgrep" for searching for fixed strings.

> true. another annoying flase positive thing since the move to SVN is
> that duplicate '/.svn/' entries pop up and must be filtered out with
> 'grep -v'.

  GNU grep has `--include', so I often use something like the
  following:

$ grep -rF --include='*.[ch]' G_foo lib/ raster/

$ grep -rF --include=\*.html g.bar ./

  Unfortunately, there's no way to skip directories matching a
  wildcard (e. g.: --exclude=.svn), at least as of GNU grep 2.5.1.

  The `-l' option could be useful as well, e. g.:

$ less $(grep -rlF --include='*.[ch]' G_foo raster/)