Hamish, could this be incorporated into r.profile or at least provided as a script? There are many applications where this capability is needed and I am sure that many users would appreciate it (especially those who work with coastal data, including myself).
thanks, Helena
Hamish wrote:
is there a way to feed profile-coordinates into r.profile through a
file instead of stating them on the command line ?
I sent Peter a test version of r.profile this morning that allows coordinates to be piped in. Basically coordinates could be provided in three ways ...
coords from file
cat mycoordinates.txt | r.profile input=foo output=bat
coords on command line
r.profile input=foo output=bat profile=e,n,e,n,...
If you are interested I can make this available for testing.
--
Bob
Helena Mitasova wrote:
Hamish, could this be incorporated into r.profile or at least provided as a script? There are many applications where this capability is needed and I am sure that many users would appreciate it (especially those who work with coastal data, including myself).
thanks, Helena
Hamish wrote:
is there a way to feed profile-coordinates into r.profile through a
file instead of stating them on the command line ?
I sent Peter a test version of r.profile this morning that allows
coordinates to be piped in. Basically coordinates could be provided in
three ways ...
coords from file
cat mycoordinates.txt | r.profile input=foo output=bat
On Fri, 16 Sep 2005 14:16:16 +1200 Hamish <hamish_nospam@yahoo.com>
wrote:
> I sent Peter a test version of r.profile this morning that allows
> coordinates to be piped in. Basically coordinates could be provided
> in three ways ...
>
> coords from file
> cat mycoordinates.txt | r.profile input=foo output=bat
>
> select coords interactively
> r.profile -i input=foo output=bat
>
> coords on command line
> r.profile input=foo output=bat profile=e,n,e,n,...
>
> If you are interested I can make this available for testing.
This sounds like a nice feature to have in the main CVS version.
The modified r.profile is now in CVS. This version now accepts coordinates directly from stdin (plus the original methods). At this time it expects coordinates as space or tab seperated easting and northing. Any labels after these are ignored.
I have also added an additional flag "-c" which will output the RGB color values for each profile point. This can then be used to plot a color coded cross section.
Please give it a try and let me know if there are any problems.
--
Bob
Hamish wrote:
I sent Peter a test version of r.profile this morning that allows coordinates to be piped in. Basically coordinates could be provided in
three ways ...
coords from file
cat mycoordinates.txt | r.profile input=foo output=bat
The modified r.profile is now in CVS. This version now accepts
coordinates directly from stdin (plus the original methods). At this
time it expects coordinates as space or tab seperated easting and
northing. Any labels after these are ignored.
can you provide a short example? (preferably added to the help page)
I have also added an additional flag "-c" which will output the RGB
color values for each profile point. This can then be used to plot a
color coded cross section.
Please give it a try and let me know if there are any problems.
Nice, I look forward to checking it out.
It took me a little while to grasp what the new RGB flag did, but
yeah, I like it. (grabs the raster's color value at that coordinate)
One thing -- it outputs "RRR GGG BBB". While I think most places in
GRASS will understand that format, I've been trying to standardize on
"RRR:GGG:BBB". Mostly because the r.colors rules looked like:
0 255 255 255
1 255 255 255
2 255 255 255
etc.
Which is ok, but when the color values are closer to the data values
it makes it really hard to read, eg
0 0:255:0
is a lot easier for my eye to follow & my brain to register vs
0 0 255 0
or were you thinking of feeding the color values into multiple columns
to pass to external software? (vs r.profile with -g flag -> v.in.ascii
-> GRASSRGB column that d.vect and ps.map might understand and take
advantage of)
I have updated the help page in CVS. I have included some examples, and updated some of the other descriptions. Check it out and see if I missed anything.
You are proably right about the RGB values. I have also updated the program to now output the colors as RRR:GGG:BBB.
Check it out and let me know if you find any errors or problems.
As an example, I have attached a plot made from the RGB output. The data is display with a 15x vertical exxageration.
--
Bob
Hamish wrote:
The modified r.profile is now in CVS. This version now accepts coordinates directly from stdin (plus the original methods). At this time it expects coordinates as space or tab seperated easting and northing. Any labels after these are ignored.
can you provide a short example? (preferably added to the help page)
I have also added an additional flag "-c" which will output the RGB color values for each profile point. This can then be used to plot a color coded cross section.
Please give it a try and let me know if there are any problems.
Nice, I look forward to checking it out.
It took me a little while to grasp what the new RGB flag did, but
yeah, I like it. (grabs the raster's color value at that coordinate)
One thing -- it outputs "RRR GGG BBB". While I think most places in
GRASS will understand that format, I've been trying to standardize on
"RRR:GGG:BBB". Mostly because the r.colors rules looked like:
0 255 255 255
1 255 255 255
2 255 255 255
etc.
Which is ok, but when the color values are closer to the data values
it makes it really hard to read, eg
0 0:255:0
is a lot easier for my eye to follow & my brain to register vs
0 0 255 0
or were you thinking of feeding the color values into multiple columns
to pass to external software? (vs r.profile with -g flag -> v.in.ascii
-> GRASSRGB column that d.vect and ps.map might understand and take
advantage of)
On Fri, 16 Sep 2005 12:26:11 -0300 Bob Covill <bcovill@tekmap.ns.ca>
wrote:
Hello,
I have updated the help page in CVS. I have included some examples,
and updated some of the other descriptions. Check it out and see if I
missed anything.
You are proably right about the RGB values. I have also updated the
program to now output the colors as RRR:GGG:BBB.
Check it out and let me know if you find any errors or problems.
As an example, I have attached a plot made from the RGB output. The
data is display with a 15x vertical exxageration.
Cool stuff! Works great here after a short test. Bob, would you let us
know which programm produced the nice plott attached by your last email?
Cool stuff! Works great here after a short test. Bob, would you let us
know which programm produced the nice plott attached by your last email?
I made the plot with a little TCL GUI that I had thrown together. I had hunted around for a simple plotting package that would plot the simple XY data to scale (with a set vertical exaggeration) and optionally allow RGB color input.
If interested I can make the GUI available. It probably has some bugs and could use more enhancements. Basically it loads the data and display the profile on a TCL canvas. The user can set size, vertical exaggeration, grid lines and annotation. The plot can then be saved as an EPS file. This EPS file can then be placed in a map with ps.map (eps argument).