[GRASSLIST:9462] Re: V.sample - what does the column parameter refer to?
Markus Neteler
neteler at itc.it
Tue Dec 13 20:54:26 EST 2005
Eric,
it's an existing column.
I have updated description in CVS and added this example
(I hope I got it right):
Comparison of "elevation.dem" and "elevation.10m" Spearfish maps
at random places:
#generate random points:
v.random output=random n=100
#add table with one column:
v.db.addtable random col="el10 double"
#transfer elevations at random points into table:
v.what.rast rast=elevation.10m vect=random col=el10
#verify:
v.db.select random
#generate sampling from other elevation map:
v.sample in=random col=el10 rast=elevation.dem out=elev_sample
#verify:
v.db.select elev_sample
#univariate statistics of differences between elevation maps:
v.univar elev_sample col=diff
cheers
Markus
On Fri, Dec 09, 2005 at 11:29:27AM -0400, Patton, Eric wrote:
> Is the column parameter of v.sample referring to an empty column in the
> vector attribute file, or - a new column that will be created during the
> sampling of the raster, or - an existing column?
>
> I've tried sampling a raster using an empty column I created using
> v.db.addcol (type was DOUBLE), and I got nothing but zeros populated in the
> column in question. Region was good, it was set to that of the sampling
> vector.
>
> ~ Eric.
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> Eric Patton
>
> Technologist, Geo-Spatial Data Services
> Geological Survey of Canada (Atlantic)
> Natural Resources Canada
> Bedford Institute of Oceanography
> Dartmouth, Nova Scotia, Canada B2Y 4A2
>
> Postal address: P.O. Box 1006
> Courier address: 1 Challenger Drive
>
> Telephone: (902)426-7732
> Facsimile: (902)426-4104
> E-mail: epatton at NRCan.gc.ca
>
>
--
Markus Neteler <neteler itc it> http://mpa.itc.it
ITC-irst - Centro per la Ricerca Scientifica e Tecnologica
MPBA - Predictive Models for Biol. & Environ. Data Analysis
Via Sommarive, 18 - 38050 Povo (Trento), Italy
More information about the grass-user
mailing list