Re: [Qgis-user] Domains darstellen

2012-09-17 Thread Marco Hugentobler

Hi

If you are working with M-Shapefiles, the event layer plugin in the 
public repository (http://plugins.qgis.org/plugins/event_layer/) 
provides similar functionality as the event layer function in arcview. 
Don't know if it can be usefull for your purpose.


Regards,
Marco

On 17.09.2012 08:47, Paolo Cavallini wrote:

Il 16/09/2012 19:12, carann00 ha scritto:


it would be helpful also to know if there is a tool in QGIS as described in
the link (dynamischen Segmentierung) or some like that. I would then try to
reproduce the M-vale with the original data.

Have a look to http://hub.qgis.org/projects/lrs
Please let us know how it goes.
All the best.



--
Dr. Marco Hugentobler
Sourcepole -  Linux  Open Source Solutions
Weberstrasse 5, CH-8004 Zürich, Switzerland
marco.hugentob...@sourcepole.ch http://www.sourcepole.ch
Technical Advisor QGIS Project Steering Committee

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Copy / paste features to spatialite generates

2012-09-17 Thread Julian Bogdani
Hi Josef
and thank you for your reply. I am actually using Qspatialite plugin to manage 
my spatialite layers. I checked the metadata of my database and my geometry 
column is of type MULTISTRING.
I use Qspatialite to transform shapefiles in spatialite and the other way, but 
I'm not sure how to use it to copy only some feature from a shapefile to a 
spatialite table. I think I have to upload it to the spatialite archive and 
then use sql to copy data from one table to another.

I'm afraid this is not so user-friendly, and my colleagues can hardly handle 
data in this way. Maybe actually it's better to continue using shapefiles as 
feature containers and wait until spatialite becomes a little bit more handily.


-
Julian Bogdani
jbogd...@gmail.com
http://bradypus.net





On 17 Sep 2012, at 2:01 , Josef K wrote:

 Hi Julian
 
 I guess your problem is related to geometry types 
 (http://www.gaia-gis.it/spatialite-2.4.0-4/spatialite-cookbook/html/new-geom.html).
  Try to define your spatialite geometries as multipoint, multilinestring and 
 multipolygons. Then they will be more compatible with shapefiles and you may 
 copy/paste in qgis. 
 
 Although I would recommend that you tried using spatialite-gui (or perahaps 
 qspatialite) instead. By those tools you can temporarily upload the shapefile 
 to your database file and then use sql syntax 'insert into ... select ... ' 
 the features you want into your db tables. Using sql syntax will give you 
 more control of fields, data types etc. 
 
 regards
 Josef
 
 Date: Sun, 16 Sep 2012 11:53:30 +0200
 From: Julian Bogdani jbogd...@gmail.com
 To: qgis-user qgis-user@lists.osgeo.org
 Subject: [Qgis-user] Copy / paste features to spatialite generates
 error
 Message-ID: a7512d49-0f85-4cb5-a3d2-85da4919e...@gmail.com
 Content-Type: text/plain; charset=us-ascii
 
 Hello all,
 I've tried to add to an existing spatialite layer some features from another 
 layer.
 The existing layer is a simple shapefile: I selected the features I wanted to 
 copy and pasted to the spatialite layer. Everything was working file until I 
 tried to save the changes. The following error appears:
 
 Could not commit changes to layer Plan_gen
 
 Errors: ERROR: 903 feature(s) not added.
 Provider errors:
 SQLite error: Plan_gen.Geometry violates Geometry constraint [geom-type or 
 SRID not allowed]
 SQL: INSERT INTO Plan_gen(PKUID,Geometry,Layer,area) VALUES 
 (NULL,GeomFromWKB(?, 32634),?,?)
 
 
 it states it might be a problem of geometry type or a SRID problem. All 
 layers are in the same CRS (EPSG:32634), and all features, in both layers, 
 are of type polyline.
 
 Is it a spatialite bug? a qgis bug? or Am I missing anything?
 
 I've had this issue with other data before. The solution I adopted to work 
 around this was:
 1) save the spatialite layer as shapefile
 2) paste data into the newly created shapefile
 3) delete the spatialite table
 4) load in the spatialite DB the shapefile
 
 This works, but it is too tricky for everyday use. I tried to convert all my 
 shapefiles to spatialite, but the limitation spatilite still have in data 
 structure manipulation (adding/removing/renaming fields, etc, a sqlite limit 
 in fact) and now in content editing make me think that that was not a good 
 idea. I can not switch this archives to postGIS yet, because of the actual 
 work-flow organization of the project.
 
 Any help or advice will be appreciated!
 
 
 -
 Julian Bogdani
 jbogd...@gmail.com
 http://bradypus.net

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Domains darstellen

2012-09-17 Thread carann00
Thank you Marco and Paolo,

I never used plugins... I have to check how to use/install/import/etc. these
two. ;-)
 
Meanwhile in my .shp I could create a new attribute length.

According to my internet research, in ESRI is possible to display a
scale..
http://help.arcgis.com/de/arcgisdesktop/10.0/help/index.html#//0039001n00

This is exactly what I need!

In QGIS I found in Symbology/ Symbolproperties/Markierungslinie a similar
feature. However, it is not possible to set an intervall-length for
kilometer. Any Idea if there is something similar in QGIS?





--
View this message in context: 
http://osgeo-org.1560.n6.nabble.com/Domains-darstellen-tp5001862p5002282.html
Sent from the Quantum GIS - User mailing list archive at Nabble.com.
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Domains darstellen

2012-09-17 Thread Werner Macho
Hi!

That sounds like my point on the wishlist
https://docs.google.com/document/d/1CTjrXWu0EJqLWcKU2ifBoQKPwXlZAkZnSzewq8zsamM/edit#heading=h.ggk1rwwhya4q

Point 3: Add Points along line aka route labelling

There is some workaround here
http://woostuff.wordpress.com/2012/08/05/generating-chainage-distance-nodes-in-qgis/

but it seems not to be meaned for the enduser ;)

So no - not in QGIS right now - but hopefully sometime

HTH

kind regards
Werner

On 09/17/2012 10:39 AM, carann00 wrote:
 Thank you Marco and Paolo,

 I never used plugins... I have to check how to use/install/import/etc. these
 two. ;-)
  
 Meanwhile in my .shp I could create a new attribute length.

 According to my internet research, in ESRI is possible to display a
 scale..
 http://help.arcgis.com/de/arcgisdesktop/10.0/help/index.html#//0039001n00

 This is exactly what I need!

 In QGIS I found in Symbology/ Symbolproperties/Markierungslinie a similar
 feature. However, it is not possible to set an intervall-length for
 kilometer. Any Idea if there is something similar in QGIS?





 --
 View this message in context: 
 http://osgeo-org.1560.n6.nabble.com/Domains-darstellen-tp5001862p5002282.html
 Sent from the Quantum GIS - User mailing list archive at Nabble.com.
 ___
 Qgis-user mailing list
 Qgis-user@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/qgis-user

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Copy / paste features to spatialite generates

2012-09-17 Thread Micha Silver

On 17/09/2012 11:07, Julian Bogdani wrote:

Hi Josef
and thank you for your reply. I am actually using Qspatialite plugin 
to manage my spatialite layers. I checked the metadata of my database 
and my geometry column is of type MULTISTRING.


Probably should be MULTILINESTRING ??

I use Qspatialite to transform shapefiles in spatialite and the other 
way, but I'm not sure how to use it to copy only some feature from a 
shapefile to a spatialite table. I think I have to upload it to the 
spatialite archive and then use sql to copy data from one table to 
another.




As Josef mentioned, it's quite easy once you get the hang of it. A 
statement like:

INSERT INTO target table ( target_col1, target_col2,...)
SELECT source_colA, source_colB
FROM source_table
WHERE condition;
will copy selected features from one table to another.

I'm afraid this is not so user-friendly, and my colleagues can hardly 
handle data in this way. Maybe actually it's better to continue using 
shapefiles as feature containers and wait until spatialite becomes a 
little bit more handily.



-
Julian Bogdani
jbogd...@gmail.com mailto:jbogd...@gmail.com
http://bradypus.net





On 17 Sep 2012, at 2:01 , Josef K wrote:


Hi Julian

I guess your problem is related to geometry types 
(http://www.gaia-gis.it/spatialite-2.4.0-4/spatialite-cookbook/html/new-geom.html). 
Try to define your spatialite geometries as multipoint, 
multilinestring and multipolygons. Then they will be more compatible 
with shapefiles and you may copy/paste in qgis.


Although I would recommend that you tried using spatialite-gui (or 
perahaps qspatialite) instead. By those tools you can temporarily 
upload the shapefile to your database file and then use sql syntax 
'insert into ... select ... ' the features you want into your db 
tables. Using sql syntax will give you more control of fields, data 
types etc.


regards
Josef

Date: Sun, 16 Sep 2012 11:53:30 +0200
From: Julian Bogdani jbogd...@gmail.com mailto:jbogd...@gmail.com
To: qgis-user qgis-user@lists.osgeo.org
mailto:qgis-user@lists.osgeo.org
Subject: [Qgis-user] Copy / paste features to spatialite generates
error
Message-ID: a7512d49-0f85-4cb5-a3d2-85da4919e...@gmail.com
mailto:a7512d49-0f85-4cb5-a3d2-85da4919e...@gmail.com
Content-Type: text/plain; charset=us-ascii

Hello all,
I've tried to add to an existing spatialite layer some features
from another layer.
The existing layer is a simple shapefile: I selected the features
I wanted to copy and pasted to the spatialite layer. Everything
was working file until I tried to save the changes. The following
error appears:

Could not commit changes to layer Plan_gen

Errors: ERROR: 903 feature(s) not added.
Provider errors:
SQLite error: Plan_gen.Geometry violates Geometry constraint
[geom-type or SRID not allowed]
SQL: INSERT INTO Plan_gen(PKUID,Geometry,Layer,area)
VALUES (NULL,GeomFromWKB(?, 32634),?,?)


it states it might be a problem of geometry type or a SRID
problem. All layers are in the same CRS (EPSG:32634), and all
features, in both layers, are of type polyline.

Is it a spatialite bug? a qgis bug? or Am I missing anything?

I've had this issue with other data before. The solution I
adopted to work around this was:
1) save the spatialite layer as shapefile
2) paste data into the newly created shapefile
3) delete the spatialite table
4) load in the spatialite DB the shapefile

This works, but it is too tricky for everyday use. I tried to
convert all my shapefiles to spatialite, but the limitation
spatilite still have in data structure manipulation
(adding/removing/renaming fields, etc, a sqlite limit in fact)
and now in content editing make me think that that was not a good
idea. I can not switch this archives to postGIS yet, because of
the actual work-flow organization of the project.

Any help or advice will be appreciated!


-
Julian Bogdani
jbogd...@gmail.com mailto:jbogd...@gmail.com
http://bradypus.net http://bradypus.net/





This mail was received via Mail-SeCure System.


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user

This mail was received via Mail-SeCure System.





___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Copy / paste features to spatialite generates

2012-09-17 Thread Julian Bogdani


On 17 Sep 2012, at 12:04 , Micha Silver wrote:

 On 17/09/2012 11:07, Julian Bogdani wrote:
 Hi Josef
 and thank you for your reply. I am actually using Qspatialite plugin to 
 manage my spatialite layers. I checked the metadata of my database and my 
 geometry column is of type MULTISTRING.
 
 Probably should be MULTILINESTRING ??

Sorry MULTISTRING is a typo!  My column's type is MULTILINESTRING.
 
 I use Qspatialite to transform shapefiles in spatialite and the other way, 
 but I'm not sure how to use it to copy only some feature from a shapefile to 
 a spatialite table. I think I have to upload it to the spatialite archive 
 and then use sql to copy data from one table to another.
 
 
 As Josef mentioned, it's quite easy once you get the hang of it. A statement 
 like:
 INSERT INTO target table ( target_col1, target_col2,...)
 SELECT source_colA, source_colB
 FROM source_table
 WHERE condition;
 will copy selected features from one table to another.

So, to sum up a possible work flow could be the following:
1) Use Qspatiaite to migrate all tables in a spatialite db
2) Write down the sql query to copy features from one table to another
3) Eventually delete the source table, if not needed

Point 2 makes me think: is there a sql statement to get  only selected rows? I 
don't think so because selection is a QGIS feature and SQL statements just 
involves origin tables, am I wrong?. In some case it's not possible to get the 
features you need by SQL statements, but just by selecting them on map.I think 
about arbitrary selections, not depending on regular patterns (attributes).
Or the solution might be to import into spatialite only the features I need. So 
in point 1 I would have:
1a) select features to copy using map view in qgis
1b) migrate only selected features to spatialite

Do you think reporting this copy/paste problem as subject for further 
enhancement could be useful, at least as far as it concerns spatialite?

Thank you



 
 I'm afraid this is not so user-friendly, and my colleagues can hardly handle 
 data in this way. Maybe actually it's better to continue using shapefiles as 
 feature containers and wait until spatialite becomes a little bit more 
 handily.
 
 
 -
 Julian Bogdani
 jbogd...@gmail.com mailto:jbogd...@gmail.com
 http://bradypus.net
 
 
 
 
 
 On 17 Sep 2012, at 2:01 , Josef K wrote:
 
 Hi Julian
 
 I guess your problem is related to geometry types 
 (http://www.gaia-gis.it/spatialite-2.4.0-4/spatialite-cookbook/html/new-geom.html).
  Try to define your spatialite geometries as multipoint, multilinestring 
 and multipolygons. Then they will be more compatible with shapefiles and 
 you may copy/paste in qgis.
 
 Although I would recommend that you tried using spatialite-gui (or perahaps 
 qspatialite) instead. By those tools you can temporarily upload the 
 shapefile to your database file and then use sql syntax 'insert into ... 
 select ... ' the features you want into your db tables. Using sql syntax 
 will give you more control of fields, data types etc.
 
 regards
 Josef
 
Date: Sun, 16 Sep 2012 11:53:30 +0200
From: Julian Bogdani jbogd...@gmail.com mailto:jbogd...@gmail.com
To: qgis-user qgis-user@lists.osgeo.org
mailto:qgis-user@lists.osgeo.org
Subject: [Qgis-user] Copy / paste features to spatialite generates
error
Message-ID: a7512d49-0f85-4cb5-a3d2-85da4919e...@gmail.com
mailto:a7512d49-0f85-4cb5-a3d2-85da4919e...@gmail.com
Content-Type: text/plain; charset=us-ascii
 
Hello all,
I've tried to add to an existing spatialite layer some features
from another layer.
The existing layer is a simple shapefile: I selected the features
I wanted to copy and pasted to the spatialite layer. Everything
was working file until I tried to save the changes. The following
error appears:
 
Could not commit changes to layer Plan_gen
 
Errors: ERROR: 903 feature(s) not added.
Provider errors:
SQLite error: Plan_gen.Geometry violates Geometry constraint
[geom-type or SRID not allowed]
SQL: INSERT INTO Plan_gen(PKUID,Geometry,Layer,area)
VALUES (NULL,GeomFromWKB(?, 32634),?,?)
 
 
it states it might be a problem of geometry type or a SRID
problem. All layers are in the same CRS (EPSG:32634), and all
features, in both layers, are of type polyline.
 
Is it a spatialite bug? a qgis bug? or Am I missing anything?
 
I've had this issue with other data before. The solution I
adopted to work around this was:
1) save the spatialite layer as shapefile
2) paste data into the newly created shapefile
3) delete the spatialite table
4) load in the spatialite DB the shapefile
 
This works, but it is too tricky for everyday use. I tried to
convert all my shapefiles to spatialite, but the limitation
spatilite still have in data structure manipulation
(adding/removing/renaming fields, etc, a sqlite limit in fact)
and now in content editing make me 

Re: [Qgis-user] Problems to display working window on MacOSX

2012-09-17 Thread José Carlos Guerrero Antúnez
Hi William,

Thank you for your help. Now, I can work whithout problem.

Regards,

Jose C. Guerrero

2012/9/15 William Kyngesburye wokl...@kyngchaos.com

 On Sep 15, 2012, at 7:55 AM, José Carlos Guerrero Antúnez wrote:

   OSX 10.6.8
   Qgis 1.8 updated.
  
   I'm working with an IMac10,1, Intel Core 2 duo

 Updated - do you mean you had a previous version of QGIS installed and you
 upgraded?  There might be extra plugins from the old version that do not
 work in QGIS.  There is a known problem of old plugins that use PyQwt will
 cause the new QGIS to crash, a couple of these are profiletool and
 valuetool.

 You can trash ~/Library/Preferences/org.qgis.QGIS.plist (that's in your
 home folder Library) and the next time you start QGIS all your extra
 plugins will be disabled (if QGIS still crashes, it's something else).
  Turn them on one by one in the plugin manager to find which one(s)
 crashes.  Either update or delete the plugin(s).  Valuetool has been
 updated for this problem but I have not heard about profiletool being
 updated.

 -
 William Kyngesburye kyngchaos*at*kyngchaos*dot*com
 http://www.kyngchaos.com/

 We are at war with them. Neither in hatred nor revenge and with no
 particular pleasure I shall kill every ___ I can until the war is over.
 That is my duty.

 Don't you even hate 'em?

 What good would it do if I did? If all the many millions of people of the
 allied nations devoted an entire year exclusively to hating the  it
 wouldn't kill one ___ nor shorten the war one day.

 Ha, ha And it might give 'em all stomach ulcers.

 - Tarzan, on war


___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Layers in qgs file not present in the Layers pane

2012-09-17 Thread Julian Bogdani
HelloI've posted a question ongis.stackexchange.com (http://gis.stackexchange.com/questions/33608/layers-in-qgs-file-not-present-in-the-layers-pane), and as promised there I'm sending here a qgis project file with a phantom layer to use for test.The phantom layer is named: "plan01_2012" and references to: "./Planimetrie/2012/plan01_2012.tif" as you can see in lines 27 and following.Opening the project with QGIS no error is showed for the missing reference, and no layer is shown in the Layers pane.Checking better I can find a reference of this layer in the "Identifiable layer" tab of Project properties.Saving project as will not purge the file.As you can see in the same file other traces of older files are still present in the xml, for instance near lines126 and following: a list of vector layer with snapping turned on. This does not produce any error, but getting them removed when layer is removed is probably cleaner.
-Julian Bogdanijbogd...@gmail.comhttp://bradypus.net





test.qgs
Description: Binary data
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Copy / paste features to spatialite generates

2012-09-17 Thread Julian Bogdani


On 17 Sep 2012, at 20:37 , Micha Silver wrote:

 Hi Julian:
 
 On 17/09/2012 13:22, Julian Bogdani wrote:
 
 
 On 17 Sep 2012, at 12:04 , Micha Silver wrote:
 
 On 17/09/2012 11:07, Julian Bogdani wrote:
 Hi Josef
 and thank you for your reply. I am actually using Qspatialite plugin to 
 manage my spatialite layers. I checked the metadata of my database and my 
 geometry column is of type MULTISTRING.
 
 Probably should be MULTILINESTRING ??
 
 Sorry MULTISTRING is a typo!  My column's type is MULTILINESTRING.
 
 I use Qspatialite to transform shapefiles in spatialite and the other way, 
 but I'm not sure how to use it to copy only some feature from a shapefile 
 to a spatialite table. I think I have to upload it to the spatialite 
 archive and then use sql to copy data from one table to another.
 
 
 As Josef mentioned, it's quite easy once you get the hang of it. A 
 statement like:
 INSERT INTO target table ( target_col1, target_col2,...)
 SELECT source_colA, source_colB
 FROM source_table
 WHERE condition;
 will copy selected features from one table to another.
 
 So, to sum up a possible work flow could be the following:
 1) Use Qspatiaite to migrate all tables in a spatialite db
 2) Write down the sql query to copy features from one table to another
 3) Eventually delete the source table, if not needed
 
 
 First, don't ignore the option (in spatialite-gui) to connect to a Virtual 
 shapefile. If you only need to copy some features into a spatialite table, 
 this is a good way to proceed. After copying the features, you can DROP the 
 virtual table.

Thank you Micha,
It seems I have to better study Spatialite :)
Just one more question: spatialite-qui is the same thing as QspatiaLite plugin? 
If so I'm not able to find this feature :(


 
 
 Point 2 makes me think: is there a sql statement to get  only selected rows? 
 I don't think so because selection is a QGIS feature and SQL statements just 
 involves origin tables, am I wrong?. In some case it's not possible to get 
 the features you need by SQL statements, but just by selecting them on map.I 
 think about arbitrary selections, not depending on regular patterns 
 (attributes).
 
 Regarding the arbitrary selection, if you need to *visually* select some 
 features, then migrate them to spatialite, I don't see any way to do this 
 automatically.  The only idea that comes to mind is, after selecting the 
 features, add a new attribute column with some value that identifies those 
 features, then connect to the shapefile (virtual shapefile in spatialite), 
 and to the INSERT INTO...SELECT FROM...WHERE... as above.
 
 Hopefully soon the ogr2ogr driver in QGIS will be improved to allow Save 
 as... directly to an existing spatialite database. Currently when you use 
 Save as... or Save selection as... the target sqlite database is 
 *overwritten*. The command line ogr2ogr has the '-append' and '-nln' (new 
 layer name) parameters to migrate i.e. a shapefile to an existing spatialite 
 DB. But it doesn't seem to be available yet in QGIS :-(
 
 Micha
 
 
 Or the solution might be to import into spatialite only the features I need. 
 So in point 1 I would have:
 1a) select features to copy using map view in qgis
 1b) migrate only selected features to spatialite
 
 Do you think reporting this copy/paste problem as subject for further 
 enhancement could be useful, at least as far as it concerns spatialite?
 
 Thank you
 
 
 
 
 I'm afraid this is not so user-friendly, and my colleagues can hardly 
 handle data in this way. Maybe actually it's better to continue using 
 shapefiles as feature containers and wait until spatialite becomes a 
 little bit more handily.
 
 
 -
 Julian Bogdani
 jbogd...@gmail.com mailto:jbogd...@gmail.com mailto:jbogd...@gmail.com
 http://bradypus.net
 
 
 
 
 
 On 17 Sep 2012, at 2:01 , Josef K wrote:
 
 Hi Julian
 
 I guess your problem is related to geometry types 
 (http://www.gaia-gis.it/spatialite-2.4.0-4/spatialite-cookbook/html/new-geom.html).
  Try to define your spatialite geometries as multipoint, multilinestring 
 and multipolygons. Then they will be more compatible with shapefiles and 
 you may copy/paste in qgis.
 
 Although I would recommend that you tried using spatialite-gui (or 
 perahaps qspatialite) instead. By those tools you can temporarily upload 
 the shapefile to your database file and then use sql syntax 'insert into 
 ... select ... ' the features you want into your db tables. Using sql 
 syntax will give you more control of fields, data types etc.
 
 regards
 Josef
 
   Date: Sun, 16 Sep 2012 11:53:30 +0200
   From: Julian Bogdani jbogd...@gmail.com mailto:jbogd...@gmail.com 
 mailto:jbogd...@gmail.com
   To: qgis-user qgis-user@lists.osgeo.org 
 mailto:qgis-user@lists.osgeo.org
   mailto:qgis-user@lists.osgeo.org
   Subject: [Qgis-user] Copy / paste features to spatialite generates
   error
   Message-ID: a7512d49-0f85-4cb5-a3d2-85da4919e...@gmail.com 
 

Re: [Qgis-user] getting statistics from a raster layer

2012-09-17 Thread Antonio Silva
Thanks Nick and Carlos,

Following the suggestions I got an error message: Cannot compute bounding
box of cutline. when  cutting the raster. I cannot understand where is the
problem. It happened only with this kind of raster. I tried with nautical
charts and georeferenced maps from Google Earth and I cut them without
problems. Any ideas?

Also I installed SAGA and GDAL. SAGA is great but it will take a time to me
to verify all options.

GDAL - statistic by zones gives part of the answer (count, sum and mean) in
a very convenient way, creating columns at the attribute table.  There's no
need to cut the raster. Nevertheless I need max and min at least. If I
could get max, min, std this way it would be the heaven.

 So, my point now is to cut the raster, or find another tool as statistic
by zones with more parameters.


All the best,


Antônio


2012/9/15 Nick Hopton nhop...@gmail.com

 I think the first thing to do is clip the raster to your area of interest
 using the vector polygon. Raster - Extraction - Clipper. Select the
 polygon shapefile as the mask layer.

 To get the statistics load the clipped raster, right-click on it in the
 layers panel, select Properties and then click the Metadata tab. This
 will show the mean, min, max and SD, but not (unfortunately) the median.

 N.



 --
 View this message in context:
 http://osgeo-org.1560.n6.nabble.com/getting-statistics-from-a-raster-layer-tp5002022p5002057.html
 Sent from the Quantum GIS - User mailing list archive at Nabble.com.
 ___
 Qgis-user mailing list
 Qgis-user@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/qgis-user




-- 
Antônio Olinto Ávila da Silva
Biólogo / Oceanógrafo
Instituto de Pesca (Fisheries Institute)
São Paulo, Brasil
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Sextante - error saving a model with Select by location tool

2012-09-17 Thread Pedro Venâncio
Hi,


I can not save a model in which is used the tool 'Select by location' from 
fTools.

When saving, it shows the error:


An error has occured while executing Python code:

Traceback (most recent call last):
  File /home/pedro/.qgis//python/plugins/sextante/modeler/ModelerDialog.py, 
line 219, in saveModel
    text = self.alg.serialize()
  File 
/home/pedro/.qgis//python/plugins/sextante/modeler/ModelerAlgorithm.py, line 
305, in serialize
    s+=unicode(self.algOutputs[i][out.name]) + \n
KeyError: 'OUTPUT'

Python version:
2.7.3 (default, Aug  1 2012, 05:27:35) 
[GCC 4.6.3]

QGIS version:
1.9.0-Master Master, exported

Python path: ['/home/pedro/.qgis//python/plugins/ogrprocessing', 
'/home/pedro/.qgis//python/plugins/sextante', '/usr/share/qgis/python', 
'/home/pedro/.qgis//python', '/home/pedro/.qgis//python/plugins', 
'/usr/share/qgis/python/plugins', '/usr/lib/python2.7', 
'/usr/lib/python2.7/plat-linux2', '/usr/lib/python2.7/lib-tk', 
'/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', 
'/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', 
'/usr/lib/python2.7/dist-packages/PIL', 
'/usr/lib/python2.7/dist-packages/gst-0.10', 
'/usr/lib/python2.7/dist-packages/gtk-2.0', '/usr/lib/pymodules/python2.7', 
'/usr/lib/python2.7/dist-packages/ubuntu-sso-client', 
'/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode', 
'/home/pedro/.qgis/python/plugins/mmqgis/forms', 
'/home/pedro/.qgis/python/plugins/qgis2kml', 
'/home/pedro/.qgis/python/plugins/qgis2kml', 
'/usr/share/qgis/python/plugins/fTools/tools']



And then, when I try to remove the module 'Select by location' from the model, 
it shows the error:

An error has occured while executing Python code:

Traceback (most recent call last):
  File 
/home/pedro/.qgis//python/plugins/sextante/modeler/ModelerGraphicItem.py, 
line 89, in removeElement
    if not self.model.removeAlgorithm(self.elementIndex):
  File 
/home/pedro/.qgis//python/plugins/sextante/modeler/ModelerAlgorithm.py, line 
164, in removeAlgorithm
    val = self.algOutputs[index][out.name]
KeyError: 'OUTPUT'

Python version:
2.7.3 (default, Aug  1 2012, 05:27:35) 
[GCC 4.6.3]

Which will be the problem?

Thank you very much!

Best regards,
Pedro Venâncio

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Automatizing map making

2012-09-17 Thread Pedro Camargo
Hi,
 I have been using QGIS for a few months now after almost a decade
using Maptitude and TransCAD (from Caliper Corporation).

 Now that I already know how to get around pretty well with QGIS, I
want to use it to production of series of maps (from a few dozens to
hundreds at a time).

 My current problem is to make simple maps with graduated style and
fixed classes for several different fields on the database.

   Looking at the PyQGIS documentation helped a bit, but I got several
errors like NameError: name 'QtGui' is not defined and for many other
names/libraries in the sample code I used, so I'm pretty sure that I have
something missing that was not mentioned in the documentation or that I
missed.

   Further, I'm interested in making maps with fields that are not in the
database, so I need to make a join too (which is not mentioned anywhere in
the documentation I saw).

I would imagine that there is a way to open a project, change something
(like the fields for the graduate rendenring), update the map composer and
save the jpg, but I didn;t see anything like that...

Did anybody face a situation like this? Any recomendations?  Any sample
code you could share?

Thanks for the help,

Pedro
UC Irvine




PS - Sorry for posting in two lists, but I really have no idea where to
send this e-mail.
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Layers in qgs file not present in the Layers pane

2012-09-17 Thread Ramon Andiñach
On 18/09/2012, at 4:08, Julian Bogdani jbogd...@gmail.com wrote:

 Hello
 I've posted a question on gis.stackexchange.com 
 (http://gis.stackexchange.com/questions/33608/layers-in-qgs-file-not-present-in-the-layers-pane),
  and as promised there I'm sending here a qgis project file with a phantom 
 layer to use for test.

[snip]

 As you can see in the same file other traces of older files are still present 
 in the xml, for instance near lines126 and following: a list of vector layer 
 with snapping turned on. This does not produce any error, but getting them 
 removed when layer is removed is probably cleaner.

As a you're not hallucinating comment (rather than a solution) I also have seen 
such things, although I'm not sure I have an example to hand. 

Is it just in projects saved by QGIS 1.8?

I think from memory mine are with relative paths, and are projects originally 
started under an earlier QGIS version. 

Save As did not work for me either. 

-ramon. ___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Automatizing map making

2012-09-17 Thread pcreso
The best tool I know for scripted cartography is GMT (Generic Mapping Tools). 
ogr2ogr will execute database queries  output GMT compatible datasets.

For things like for species in list, draw map it is very powerful  
effective. But doesn't help with how QGIS can do this I'm afraid.

Brent Wood

--- On Tue, 9/18/12, Pedro Camargo veigacama...@gmail.com wrote:

From: Pedro Camargo veigacama...@gmail.com
Subject: [Qgis-user] Automatizing map making
To: qgis-user@lists.osgeo.org, qgis-develo...@lists.osgeo.org
Date: Tuesday, September 18, 2012, 11:07 AM

Hi, I have been using QGIS for a few months now after almost a decade using 
Maptitude and TransCAD (from Caliper Corporation).    Now that I already 
know how to get around pretty well with QGIS, I want to use it to production of 
series of maps (from a few dozens to hundreds at a time).

  My current problem is to make simple maps with graduated style and fixed 
classes for several different fields on the database.    Looking at the PyQGIS 
documentation helped a bit, but I got several errors like NameError: name 
'QtGui' is not defined and for many other names/libraries in the sample code I 
used, so I'm pretty sure that I have something missing that was not mentioned 
in the documentation or that I missed.

    Further, I'm interested in making maps with fields that are not in the 
database, so I need to make a join too (which is not mentioned anywhere in the 
documentation I saw). I would imagine that there is a way to open a 
project, change something (like the fields for the graduate rendenring), update 
the map composer and save the jpg, but I didn;t see anything like that...

 Did anybody face a situation like this? Any recomendations?  Any sample 
code you could share? Thanks for the help, PedroUC Irvine 

   PS - Sorry for posting in two lists, but I really have no idea where to send 
this e-mail.

-Inline Attachment Follows-

___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/qgis-user