Re: [Qgis-user] Create a polygon with a specific area size

2024-08-27 Thread Ujaval Gandhi via QGIS-User
Yes, thanks Andrea. The scaling factor is the square root of Y/X.

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/l/75c7a0eec4fbbbad31e850fd34dcd288da9eb9d3?url=http%3A%2F%2Fwww.spatialthoughts.com&u=8747767&signature=a321f1b8575aaafb]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Tue, Aug 27, 2024 at 9:43 PM Andrea Giudiceandrea via QGIS-User
 wrote:


> > Ujaval Gandhi ujaval at spatialthoughts.com [http://spatialthoughts.com]
> > Tue Aug 27 07:28:22 PDT 2024
> 
> > If you 'Identify' the polygon, it will display the polygon Area in square
> meters
> > under the 'Derived' section. Let's call this X. If your desired area is Y,
> > the scaling factor is Y/X. Use this scaling factor and scale it using the
> > 'Scale' tool in the Advanced Digitizing toolbar.
> 
> Hi all,
> AFAIK the correct scaling factor to use is not Y/X, but the square root
> of Y/X instead.
> 
> Regards.
> 
> Andrea
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Create a polygon with a specific area size

2024-08-27 Thread Ujaval Gandhi via QGIS-User
If you 'Identify' the polygon, it will display the polygon Area in square meters
under the 'Derived' section. Let's call this X. If your desired area is Y,
the scaling factor is Y/X. Use this scaling factor and scale it using the
'Scale' tool in the Advanced Digitizing
toolbar. https://youtu.be/70CDATzucDY?si=diTLZ2CRg7oS_a0l&t=102
[https://mailtrack.io/l/88a50ea3fbf821334810b1ba5b294ba682f78a87?url=https%3A%2F%2Fyoutu.be%2F70CDATzucDY%3Fsi%3DdiTLZ2CRg7oS_a0l%26t%3D102&u=8747767&signature=a357935210c9ac24]
---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/l/52c33efac5182270f8277a3a6800f91491bc8cb9?url=http%3A%2F%2Fwww.spatialthoughts.com&u=8747767&signature=8fa5bc10ee973263]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Tue, Aug 27, 2024 at 7:18 PM Nicole Stoffels via QGIS-User
 wrote:


> Dear all,
> 
> 
> 
> 
> I want to create a polygon of a specific size. Currently I am working rather
> "hands on". As long as it is a rectangle and I provide either length or width,
> I can calculate the other one and do a construction with the advanced
> digitizing tool. But is there a way, that I construct a more complex polygon
> and define the area beforehand or scale it to a certain area afterwards. To my
> understanding the polygon scaling requires a factor. I cannot scale to a
> certain area size in square meters. Is there another function I haven't found
> yet?
> 
> 
> 
> 
> I am using QGIS 3.34.4. 
> 
> 
> 
> 
> 
> Best regards and thank you so much in advance!
> 
> 
> Nicole Stoffels
> 
> 
>  
> 
> 
> 
> 
> 
> 
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] recommended QGIS Container-image for PyQGIS in standalone scripts

2024-08-14 Thread Ujaval Gandhi via QGIS-User
You can install qgis via conda which gives a functioning environment where you
can run pyqgis standalone without any additional
setup https://aneto.pt/posts/tutorials/2019-05-29-using-qgis-from-conda/
[https://mailtrack.io/l/0cf27eaaf5a65a913ff736c23e92f10bb2a858d1?url=https%3A%2F%2Faneto.pt%2Fposts%2Ftutorials%2F2019-05-29-using-qgis-from-conda%2F&u=8747767&signature=012874e84d2ab1f8]
 


You can also set appropriate environment variables on your standard QGIS install
and run QGIS in a headless mode. Setup instructions for Windows and Mac are
at 
https://courses.spatialthoughts.com/pyqgis-masterclass.html#writing-standalone-python-scripts
[https://mailtrack.io/l/51d2157c10ae6d8b81038af01a94155871ac1276?url=https%3A%2F%2Fcourses.spatialthoughts.com%2Fpyqgis-masterclass.html%23writing-standalone-python-scripts&u=8747767&signature=464afe13f5ed03f3]

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/l/87d0691d71748c20d7fee82bca4ad8a10405e8c8?url=http%3A%2F%2Fwww.spatialthoughts.com&u=8747767&signature=2c031c7e8843dd91]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Wed, Aug 14, 2024 at 2:05 PM Marco Lechner via QGIS-User
 wrote:


> Hallo,
> 
>  
> 
> is there any Container-image that is recommended, if I want to run a PyQGIS
> standalone script like described in the PyQGIS Developer Cookbook [1] in a
> container?
> 
> The code I want to run does not need any additional python-libs and no
> GUI-QGIS. I wonder if there is such a thing like “headless-QGIS” in an Image?
> The official image on Dockerhub [2] seems to be very large for that. Or is
> that the way to go?
> 
>  
> 
> Regards
> 
> Marco
> 
>  
> 
> [1] https://docs.qgis.org/3.34/en/docs/pyqgis_developer_
> cookbook/intro.html#using-pyqgis-in-standalone-scripts
> [https://docs.qgis.org/3.34/en/docs/pyqgis_developer_cookbook/intro.html#using-pyqgis-in-standalone-scripts]
> 
> [2] https://hub.docker.com/r/qgis/qgis/tags
> [https://hub.docker.com/r/qgis/qgis/tags]
> 
>  
> 
> i.A. Dr. Marco Lechner
> 
> Leiter Fachgebiet RN 1 │ Head section RN 1
> 
>  
> 
> --
> 
> Bundesamt für Strahlenschutz │ Federal Office for Radiation Protection
> 
> Koordination Notfallschutzsysteme │ Coordination of Emergency Response Systems
> │ RN 1
> 
> Rosastr. 9
> 
> D-79098 Freiburg
> 
>  
> 
> Tel.: +49 30 18333-6724
> 
> E-Mail: mlech...@bfs.de [mlech...@bfs.de]
> 
> #gernperDu | #CallMeByMyFirstName
> 
> www.bfs.de [http://www.bfs.de/]
> 
> 🌐 Besuchen [https://www.bfs.de/] Sie unsere Website, folgen Sie uns auf
> Mastodon [http://social.bund.de/@strahlenschutz] und abonnieren
> [https://www.bfs.de/strahlenschutzaktuell] Sie unseren 📢 Newsletter.
> 
> 🔒 Informationen zum Datenschutz [https://www.bfs.de/datenschutz] gemäß
> Artikel 13 DSGVO
> 
> 💚 E-Mail drucken? Lieber die Umwelt schonen!
> 
>  
> 
>  
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] ROUTE POINTS

2024-07-31 Thread Ujaval Gandhi via QGIS-User
Hi Humberto,The problem you want to solve is called the 'Travelling Salesman' or 'Route Optimization' problem. Thanks Emma for sharing our network analysis tutorial. I cover how to do Route Optimization using OpenRouteService API briefly at the end https://www.youtube.com/live/fL7udaJQEm8?si=sIe_6FYaiGFv6Sk8&t=4942I am not aware of a QGIS-only solution to this. However, it is fairly straightforward to do if you know PythonHere's the notebook showing the approach https://nbviewer.org/github/amitkb3/python_spatial_analysis_final_project/blob/master/PythonSpatialAnalysisCourse_FinalProject.ipynbIf you are new to ORS API, you can watch our Introduction to OpenRouteService API video https://www.youtube.com/watch?v=WBip-hbQYnM&list=PLppGmFLhQ1HJspXSA0asH9kw1OhlLrxHT&index=18---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Thu, Aug 1, 2024 at 5:57 AM Emma Hain via QGIS-User  wrote:Check out the Spatial Thoughts tutorials on network analysis youtube or tutorials available on lineOn Wed, 31 Jul 2024 at 04:39, Humberto Vargas Espinoza via QGIS-User  wrote:







Good morning
I have a file with more than 100 georeferenced points, how can I create a route with all the points or an optimal route using the roads?



De: QGIS-User 
En nombre de Andrea Giudiceandrea via QGIS-User
Enviado el: martes, 30 de julio de 2024 02:50
Para: g...@lexort.com; qgis-user@lists.osgeo.org
Asunto: Re: [Qgis-user] QGIS.org new website now online


 
> Greg Troxel gdt
 at lexort.com
> Wed Jul 24 08:52:23 PDT 2024
 
> I'm writing here because I'm having a hard time sorting "substantive"
> being spelling with serious content issues not.  I have a lot of
> comments but I think the above would sort them into things that are not
> clearly micro bugs.Hi Greg,I think it would be useful if you wrote your suggestions to the Developer mailing list or created a new issue report on https://github.com/qgis/QGIS-WebsiteRegards.Andrea











 



  
  







Este mensaje (incluyendo cualquier documento adjunto) contiene información confidencial prevista para un individuo y propósito específico, y es protegido por la Ley. Si usted no es el receptor previsto, debe suprimir este mensaje, y se notifica por este medio
 que cualquier acceso, copia, o la distribución de este mensaje, o el tomar cualquier acción basada en él, están terminantemente prohibidos. Por favor sea considerado con el medio ambiente, no utilice papel.



This message (including any attachments) contains confidential information intended for a specific individual and purpose, and is protected by law. If you are not the intended recipient, you should delete this message and are hereby notified that any disclosure,
 copying, or distribution of this message, or the taking of any action based on it, is strictly prohibited. Please consider the environment, do not use paper.





___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
-- Emma Hain — Product Manager/Senior GIS Analyst
e...@north-road.com 





North RoadCartography • Development • Spatial Analysis
north-road.com 
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Create virtual fields with pyQGIS with standalone scripts

2024-07-26 Thread Ujaval Gandhi via QGIS-User
For running a PyQGIS script as a standalone script, you need to set
appropriate environment variables and initialize qgis in a headless mode. See
the full example with setup for Windows and Mac
at 
https://courses.spatialthoughts.com/pyqgis-masterclass.html#writing-standalone-python-scripts
[https://mailtrack.io/l/54a2bb23bb2e216749cf31c77063d79fd7f518f8?url=https%3A%2F%2Fcourses.spatialthoughts.com%2Fpyqgis-masterclass.html%23writing-standalone-python-scripts&u=8747767&signature=20c626c64e491be4]

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/l/0759060cce5dfd1efebd0082630133103cf22d2a?url=http%3A%2F%2Fwww.spatialthoughts.com&u=8747767&signature=8d3fc0a0dc5f7c99]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Fri, Jul 26, 2024 at 4:16 PM Roland Berger via QGIS-User
 wrote:

> Hi
> 
> I would like to add a virtual field to a PostGIS vector layer with PyQGIS with
> standalone scripts (https://docs.qgis.org/3.34/en/docs/pyqgis_developer_
> cookbook/intro.html#python-applications
> [https://docs.qgis.org/3.34/en/docs/pyqgis_developer_cookbook/intro.html#python-applications]
> )
> All examples I have found so far with google, chatgpt4 and JetBrains AI
> Assistant gave me solutions that do not work. They only work in the Python
> Console inside QGIS.
> Does anybody know of a solution that works with PyQGIS with standalone
> scripts?
> See below what I have tried so far in different variations.
> 
> Thanks for any help
> Roland
> 
> Example created by chatgpt:
> ...
> 
> 
> field_name = "virtual_field"
> 
> expression = '"attribute_name" * 2'  # Example expression
> 
> # Create and add the virtual field
> 
> layer.startEditing()
> 
> layer.addExpressionField(expression, QgsField(field_name, QVariant.Double))
> 
> layer.commitChanges()
> 
> ...
> 
> 
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] QGIS action to run a command in a terminal window on Windows

2024-05-06 Thread Ujaval Gandhi via QGIS-User
You can use the 'Execute SQL' algorithm from Processing Toolbox to run the SQL query. You can trigger any processing algorithm from an Action that will run on any platform. Example of how to run a processing algorithm from a Python Action https://courses.spatialthoughts.com/qgis-actions.html#creating-isochrones-using-ors-tools-plugin---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Tue, May 7, 2024 at 5:39 AM Brent Wood via QGIS-User  wrote:






Hi,




I'm trying to create an action to run an SQL on a spatialite database & show the result as a QGIS action.




In Linux this works by running a script in an xterm, but I can't work out how to do something similar under widows.




Any suggestions?




Thanks





Brent Wood

Principal Technician, Fisheries
NIWA
DDI:  +64 (4) 3860529



From: QGIS-User  on behalf of Brent Wood via QGIS-User 
Sent: Wednesday, March 6, 2024 09:33
To: 'Qgis-user@lists.osgeo.org' 
Cc: Nyall Dawson 
Subject: [Qgis-user] Problem: Can't open Spatialite tables in QGIS on Windows
 




Hi,




We have been using QGIS & Spatialite for years and have recently encountered a problem in QGIS under Windows.




We connect to a spatialite database fine, we can list the tables, but when we try to open them we get an error:

db <...> table <...> is an invalid layer - not loaded (this is also written to the log)




I can open the db in DBManager and enter the query "select * from t_transect;" which runs & shows the data in the output pane.

When I try to load the layer as a map layer I get an error message referring me to the error log, but the log is empty.




This is using QGIS 3.34.1 on Windows.




The same database file works perfectly on Linux, with QGIS v3.34.3. A colleague has tried this & v3.36 on Windows with the same problem. The databases are generated with echo sounder data by the ESP3 application, and we have been able to use these in QGIS for
 years without problems until now.




Spatialite access the tables fine, the basic metadata is present:
select * from geometry_columns;
t_transect|geom_col|1|2|4326|0
t_echoint_transect_1d|geom_col|1|2|4326|0




The QGIS error message is not particularly helpful in determining the problem. Our workaround is to run the SQL we would have run in the QGIS database manager directly from the spatialite command line, exported to CSV & then open the CSV in QGIS, which works,
 but is not ideal.

 

For some context about these data:  The figure shows each "ping" from the echo sounder, scaled by the magnitude of the echo from fish, showing the location and density of fish encountered on each transect (ESP3 is used for the acoustic analysis). This dataset
 was from surveying a hill off the west coast of New Zealand (generated on Linux!).





Brent Wood

Principal Technician, Fisheries
NIWA
DDI:  +64 (4) 3860529









Brent Wood 
Principal Technician - GIS and Spatial Data Management
Programme Leader - Environmental Information Delivery
+64-4-386-0529

National Institute of Water & Atmospheric Research Ltd (NIWA)
301 Evans Bay Parade Hataitai Wellington New Zealand
Connect with NIWA: niwa.co.nz 
Facebook 
LinkedIn 
Twitter 
Instagram 
YouTube 






To ensure compliance with legal requirements and to maintain cyber security standards, NIWA's IT systems are subject to ongoing monitoring, activity logging and auditing. This monitoring and auditing service may be provided by third
 parties. Such third parties can access information transmitted to, processed by and stored on NIWA's IT systems.

Note: This email is intended solely for the use of the addressee and may contain information that is confidential or subject to legal professional privilege. If you receive this email in error please immediately notify the sender and delete the email.



___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] How QGIS handles on-the-fly projection?

2024-02-29 Thread Ujaval Gandhi via QGIS-User
There is specific code for QGIS to handle transformation between EPSG:3857 and
EPSG:4326 due to EPSG:3857 not being valid at poles. See the comments at
https://github.com/qgis/QGIS/blob/master/src/core/proj/
qgscoordinatetransform.cpp#L585
[https://mailtrack.io/l/3b9f0f5d1696eca585d974232660d3c67b88aeef?url=https%3A%2F%2Fgithub.com%2Fqgis%2FQGIS%2Fblob%2Fmaster%2Fsrc%2Fcore%2Fproj%2Fqgscoordinatetransform.cpp%23L585&u=8747767&signature=160430bc5e3e39b2]


You should not be using EPSG:3857 for datasets that span more than +/-85 degrees
latitude. If you want to display global datasets in a projected CRS, try Equal
Earth (EPSG:8857). 


---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/l/23351823d4981a6feab4bb8e2f53958dd02b7b6f?url=http%3A%2F%2Fwww.spatialthoughts.com&u=8747767&signature=f6b62978c9915c25]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Wed, Feb 28, 2024 at 6:32 PM Régis Haubourg via QGIS-User
 wrote:


> Hi ,
> 
> 
> the render in QGIS is always done on the fly, there is no caching of
> prerendered data, except for online webservices. 
> 
> PROJ is indeed the library doing the job. 
> 
> Régis
> 
> 
> On 27/02/2024 14:00, Ionut Ungurianu via QGIS-User wrote:
> 
> 
> > Hi!
> > 
> > I’m looking to understand  in a more advanced way how QGIS handles 
> > on-the-fly projection.
> > In my case I set the project crs in epsg:3857 and I have a raster layer in 
> > epsg:4326. In this case what is happening with the layer?
> > 
> > I know that it’s based on PROJ, but I’m wondering what is actually 
> > happening in the back-end, what is happening in the map canvas, how is the 
> > layer render, is being resampled every time you pan the map or do zoom 
> > in/out ...
> > 
> > So, if someone can help with a detailed explanation, I would really 
> > appreciate it.
> > 
> > Thanks in advance!
> > 
> > All the best!
> > Ionut
> > ___
> > QGIS-User mailing list
> > QGIS-User@lists.osgeo.orgqgis-u...@lists.osgeo.org
> > List info: 
> > https://lists.osgeo.org/mailman/listinfo/qgis-userhttps://lists.osgeo.org/mailman/listinfo/qgis-user
> > Unsubscribe: 
> > https://lists.osgeo.org/mailman/listinfo/qgis-userhttps://lists.osgeo.org/mailman/listinfo/qgis-user
> 
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Batch Processing Tool for Wedge Buffers

2024-02-11 Thread Ujaval Gandhi via QGIS-User
Should be possible. Use Autofill -> Calculate by _expression_ can build an _expression_ that takes the Layer (you have access to the current layer variable in _expression_ builder) and the Row number (rownumber variable) and get the attribute value of 'Azimuth' field. ---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Sun, Feb 11, 2024 at 9:32 PM krishna Ayyala  wrote:Ujaval,Thanks for the reply. When I add  generate_series _expression_ and click ok, only one more row is getting added to the batch process tool. i.e.90 degree azimuth got added. 180 and 270 were not added. Is there a way that, the batch tool can read directly from the attribute table and generate the wedge buffers? The reason is; the example that I gave has only four features.But my original file has 100 features. It will be difficult to enter all 100 values manually. If the tool can pull these values from the attribute table and generate wedge buffers that will be free of errors.On Sun, Feb 11, 2024 at 5:19 AM Ujaval Gandhi  wrote:click 'Autofill' -> Add Values by _expression_ and use _expression_ generate_series(90, 270, 90)You will get 4 layers, one for each azimuth value. Use 'Merge Vector Layers' tool to merge them into a single layer.---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Sun, Feb 11, 2024 at 3:25 AM krishna Ayyala via QGIS-User  wrote:Hello, I have opened Batch Processing tool for wedge buffers. In this, how do I use the Auto fill function such that, I get the four rows with azimuths 0,90,180,270 without me having to manually input the azimuth values for the attribute table as shown below.

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Batch Processing Tool for Wedge Buffers

2024-02-11 Thread Ujaval Gandhi via QGIS-User
click 'Autofill' -> Add Values by _expression_ and use _expression_ generate_series(90, 270, 90)You will get 4 layers, one for each azimuth value. Use 'Merge Vector Layers' tool to merge them into a single layer.---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Sun, Feb 11, 2024 at 3:25 AM krishna Ayyala via QGIS-User  wrote:Hello, I have opened Batch Processing tool for wedge buffers. In this, how do I use the Auto fill function such that, I get the four rows with azimuths 0,90,180,270 without me having to manually input the azimuth values for the attribute table as shown below.

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Oriented Points

2023-11-27 Thread Ujaval Gandhi via QGIS-User
If you want to add the angle of the underlying road automatically, this is doable using aggregate() _expression_ to obtain the intersecting road sement and then obtaining the angle of the line using angle_at_vertex() function. You can set it up so it gets filled automatically as soon as you add the point. See the example at https://courses.spatialthoughts.com/advanced-qgis.html#auto-populate-field-values---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Mon, Nov 27, 2023 at 7:21 PM Huesmann, Michaela via QGIS-User  wrote:







Thank you, Ujaval Gandhi. 'Measure Angle' is a good idea. I didn’t know that tool!
I would like to have the points oriented tot he underlaying road.
 
Von: Ujaval Gandhi  
Gesendet: Montag, 27. November 2023 14:47
An: Huesmann, Michaela Steinfurt.de>
Cc: qgis-user@lists.osgeo.org
Betreff: Re: [Qgis-user] Oriented Points
 

I see. If the angle is from a fixed reference point, you can add an _expression_ using azimuth() function in the Attribute Form that sets the default value of the attribute to the angle between the current point and the target point. If your
 reference point is not fixed but you need to select it manually, you can add the angle after digitizing. Use the 'Measure Angle' tool from the toolbar and measure the angle between the target point and reference point. Make sure to enable snapping so you get
 the exact point coordinates. Copy/Paste the result into the attribute table.




---

Ujaval Gandhi


Spatial Thoughts


www.spatialthoughts.com


 




 






On Mon, Nov 27, 2023 at 6:04 PM Huesmann, Michaela via QGIS-User  wrote:





Hello,
 
Thanks for pointing out that I can capture an attribute using rotation. I already know that I can use the angle attribute to rotate the symbol. But it is very difficult to determine
 the respective angle. If I type in the value manually, I have to correct it 5 times until it is exactly as it should. This is extremely unproductive. Rotating  doesn't work with the "Rotate Object" tool.
 
From Geomedia, I'm used to the fact that when recording, you first click on the position point and then record the direction using the mouse position. That's what I was looking
 for in QGIS.
Best regards,

Michaela
 
 
 
Von: Ujaval Gandhi 

Gesendet: Montag, 27. November 2023 12:32
An: Huesmann, Michaela Steinfurt.de>
Cc: qgis-user@lists.osgeo.org
Betreff: Re: [Qgis-user] Oriented Points
 

Just add an attribute for the rotation/orientation. You can visualize them using the technique shown here https://www.communityhealthmaps.org/blog/2019/02/21/mapping-field-photos-in-qgis




---

Ujaval Gandhi


Spatial Thoughts


www.spatialthoughts.com


 




 





On Mon, Nov 27, 2023 at 4:18 PM Huesmann, Michaela via QGIS-User  wrote:





Hello QGIS group,
 
how can I digitize oriented points in QGIS? I probably have to provide information when creating the geometry type fort he object class so that the rotation can be recorded.
Must be easy I guess but didn’t found out yet.

 
Best regards,
Michaela

 






 - 48565 Steinfurt
www.steinfurt.de




Mit freundlichen Grüßen
im Auftrag
Michaela Huesmann 
IT
Fachdienst Tiefbau
 
Tel.: +49 2552 925 219
Fax:

E-Mail:

michaela.huesmann@Stadt-Steinfurt.de





Bitte denken Sie an die Umwelt, bevor Sie diese E-Mail ausdrucken.

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: 
https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: 
https://lists.osgeo.org/mailman/listinfo/qgis-user





___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: 
https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: 
https://lists.osgeo.org/mailman/listinfo/qgis-user






___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Oriented Points

2023-11-27 Thread Ujaval Gandhi via QGIS-User
I see. If the angle is from a fixed reference point, you can add an _expression_ using azimuth() function in the Attribute Form that sets the default value of the attribute to the angle between the current point and the target point. If your reference point is not fixed but you need to select it manually, you can add the angle after digitizing. Use the 'Measure Angle' tool from the toolbar and measure the angle between the target point and reference point. Make sure to enable snapping so you get the exact point coordinates. Copy/Paste the result into the attribute table.---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Mon, Nov 27, 2023 at 6:04 PM Huesmann, Michaela via QGIS-User  wrote:







Hello,
 
Thanks for pointing out that I can capture an attribute using rotation. I already know that I can use the angle attribute to rotate the symbol. But it is very difficult to determine the respective
 angle. If I type in the value manually, I have to correct it 5 times until it is exactly as it should. This is extremely unproductive. Rotating  doesn't work with the "Rotate Object" tool.
 
From Geomedia, I'm used to the fact that when recording, you first click on the position point and then record the direction using the mouse position. That's what I was looking for in QGIS.
Best regards,

Michaela
 
 
 
Von: Ujaval Gandhi  
Gesendet: Montag, 27. November 2023 12:32
An: Huesmann, Michaela Steinfurt.de>
Cc: qgis-user@lists.osgeo.org
Betreff: Re: [Qgis-user] Oriented Points
 

Just add an attribute for the rotation/orientation. You can visualize them using the technique shown here https://www.communityhealthmaps.org/blog/2019/02/21/mapping-field-photos-in-qgis




---

Ujaval Gandhi


Spatial Thoughts


www.spatialthoughts.com


 




 





On Mon, Nov 27, 2023 at 4:18 PM Huesmann, Michaela via QGIS-User  wrote:





Hello QGIS group,
 
how can I digitize oriented points in QGIS? I probably have to provide information when creating the geometry type fort he object class so that the rotation can be recorded.
Must be easy I guess but didn’t found out yet.

 
Best regards,
Michaela

 






 - 48565 Steinfurt
www.steinfurt.de




Mit freundlichen Grüßen
im Auftrag
Michaela Huesmann 
IT
Fachdienst Tiefbau
 
Tel.: +49 2552 925 219
Fax:

E-Mail:

michaela.huesmann@Stadt-Steinfurt.de





Bitte denken Sie an die Umwelt, bevor Sie diese E-Mail ausdrucken.

___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: 
https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: 
https://lists.osgeo.org/mailman/listinfo/qgis-user






___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Oriented Points

2023-11-27 Thread Ujaval Gandhi via QGIS-User
Just add an attribute for the rotation/orientation. You can visualize them using the technique shown here https://www.communityhealthmaps.org/blog/2019/02/21/mapping-field-photos-in-qgis---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Mon, Nov 27, 2023 at 4:18 PM Huesmann, Michaela via QGIS-User  wrote:









Hello QGIS group,
 
how can I digitize oriented points in QGIS? I probably have to provide information when creating the geometry type fort he object class so that the rotation can be recorded.
Must be easy I guess but didn’t found out yet. 
 
Best regards,
Michaela







 - 48565 Steinfurt
www.steinfurt.de


Mit freundlichen Grüßen
im Auftrag
Michaela
Huesmann 
IT
Fachdienst Tiefbau
 
Tel.:
+49 2552 925 219
Fax:

E-Mail:
michaela.huesmann@Stadt-Steinfurt.de




Bitte denken Sie an die Umwelt, bevor Sie diese E-Mail ausdrucken.



___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Flatgeobuf in google drive ?

2023-10-06 Thread Ujaval Gandhi via QGIS-User
Google Drive doesn't allow static file hosting (it used to, but stopped around
2015). So you cannot use it to get a file URL that can be directly used to get
the file contents. You'll need to host the file on a static file server or a
cloud bucket (Google Cloud Storage or AWS s3)


---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/8aae70f5bd6ada7857cc248f40e8d91737f68592?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=1b1622ce093fbb24]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Fri, Oct 6, 2023 at 11:56 AM Adam Nielsen via QGIS-User
 wrote:


> > However, I would like to use Google Drive as a data repository instead
> > of the website,  so I uploaded the same file to (my) Google Drive in the
> > "Shared Data" directory and made it public viewable using a https
> > address similar to this:
> >
> > *https://drive.google.com/file/d/180sZv..
> [https://drive.google.com/file/d/180sZv..].. a lot of letters and
> > numbersUe/view?usp=sharing*
> >
> > The question: Is there any method so QGIS can access to the .fgb file
> > located in Google Drive using the information in the above https address ?
> 
> I'm no expert on Google Drive but it looks like you're using the URL
> for the friendly "view this file" page, rather than the URL that
> contains the raw file content itself.
> 
> You'll probably have to try to download the file and grab the download
> URL it gives you there and use that instead.
> 
> Cheers,
> Adam.
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] how to count overlays of objects

2023-08-18 Thread Ujaval Gandhi via QGIS-User
If your goal is to have a heatmap of polygon overlaps - it's actually
very simple. Use the Blending Mode to 'Multiply' for 'Features' and the layer
will be rendered with darker colors at the regions of overlaps


See the screenshot https://i.imgur.com/fcdB7h6.png
[https://mailtrack.io/trace/link/732b10cae06f133e97cdeeca8cc037a0b2bca537?url=https%3A%2F%2Fi.imgur.com%2FfcdB7h6.png&userId=8747767&signature=9651e967590f9544]

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/1be9ce20e165c06e6cb5dd4e4e0956d4dc28808e?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=93852ec6d31da55c]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Fri, Aug 18, 2023 at 7:45 PM Daniela Friebel via QGIS-User
 wrote:


> Dear Community
> 
>  
> 
> I have a vectorlayer with many objects (polygons) that overlap. Now I want to
> create a new layer, where each overlap results in a separate object, which has
> an attribute with the number of overlaps.
> 
> I have already tried various things, but have not yet found a solution. With
> the "union" tool I can generate the overlaps as objects, but I cannot count
> the number of overlaps. 
> 
> I am grateful for any help and hints.
> 
>  
> 
> (I would like to count the overlaps to eventually create a heatmap. If there
> is a completely different way of doing this, I would also appreciate a tip).
> 
>  
> 
> Kind regards
> 
> Daniela
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Shifting a Geotiff image

2023-08-13 Thread Ujaval Gandhi via QGIS-User
Hi Grant - You can do this with a simple Linear transform using the built-in
Georeferencer. I made a small video showing
how https://www.youtube.com/watch?v=8a4M32Rkwck
[https://mailtrack.io/trace/link/ebfeb1e55e3f8462089ce55d97e05185ae0619ed?url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D8a4M32Rkwck&userId=8747767&signature=8f549a955495bf81]


Hope that helps.

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/69c992a0409ae934c5c0e2276997a6ee22503015?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=16f533b4cb0820fe]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Sat, Aug 12, 2023 at 9:48 PM Martin Weis via QGIS-User
 wrote:


> Dear Perth,
> 
> On 11/08/2023 09:14, Grant Boxer via QGIS-User wrote:
> > I have a GeoTIFF image created using Web ODM and is mis-aligned by 1 to 1.5
> > m and I would like to move the image to register with the surveyed ground
> > control points. I can see vector tools to do this, but no raster tools.
> > Anyone have any suggestions.
> 
> 
> If it just a bit off, then the plugin "Freehand raster georeferencer"
> can be quick to shift it, otherwise use georeferencer from core (Layer -
> georeferencer), which is especially more flexible and the right tool if
> you have GCPs that you can use.
> Be careful, sometimes crashes can occur with certain transformation
> types, so better save beforehand (autoSaver and MemoryLayerSaver are
> your friends).
> 
> > Image created in WGS84 z51S.
> 
> Sound like UTM (good, metric CRS), though WGS84 might be geographic CRS
> (worse, pixel size undefined/different in x,y).
> 
> Cheers
> Martin
> 
> 
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] connect QGIS with python

2023-08-06 Thread Ujaval Gandhi via QGIS-User
You can install QGIS using conda
[https://gisunchained.wordpress.com/2019/05/29/using-qgis-from-conda/] along
with other required packages in the same environment. This is the easiest way to
ensure python dependencies are found correctly. If this is not feasible for you,
you can refer to the documentation
[https://docs.qgis.org/3.28/en/docs/pyqgis_developer_cookbook/intro.html#running-custom-applications]
which has pointers on how to set your PYTHONPATH


You can use all QGIS functionality, includig processing algorithms in a headless
mode. See my guide
at 
https://courses.spatialthoughts.com/pyqgis-in-a-day.html#writing-standalone-python-scripts
[https://mailtrack.io/trace/link/c33fcf55a40a973c7257e78375b291fb5ac40ff9?url=https%3A%2F%2Fcourses.spatialthoughts.com%2Fpyqgis-in-a-day.html%23writing-standalone-python-scripts&userId=8747767&signature=d37ba1c90b9723a7]
 


I also gave a talk recently and demonstrated the setup required to launch a
custom pyqgis algorithm from a web app. You can find the materials and video at 
http://bit.ly/automating-geospatial-qgis
[https://mailtrack.io/trace/link/a6fab34e22cbe38854a288b16087a07c01f35a5d?url=http%3A%2F%2Fbit.ly%2Fautomating-geospatial-qgis&userId=8747767&signature=d0d515c797aa16b3]



Good luck.
---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/d900ac0c48e3d561fb2ae71ca20b9e521c00612f?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=4baa3836b075f66e]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Mon, Aug 7, 2023 at 10:58 AM Pinkal Sanoria via QGIS-User
 wrote:

> please revert back as soon as possible, because it is very important for me. 
> 
> 
> Thanks 
> Pinkal
> 
> 
> 
> 
> 
> 
> 
> On Fri, Jul 28, 2023 at 12:53 AM Pinkal Sanoria  [pinkalsanoria...@gmail.com]> wrote:
> 
> > Dear QGIS Team,
> > 
> > 
> > I hope this email finds you well. My name is Pinkal, and I am a developer
> > interested in leveraging the capabilities of QGIS within a web application.
> > I am reaching out to seek guidance and support on how to connect QGIS with
> > Python, specifically Django, to utilize the full functionality of QGIS in a
> > web-based environment.
> > 
> > 
> > My objective is to integrate QGIS functionality into a Django-based web
> > application, enabling users to access and interact with geospatial data and
> > perform various geospatial analyses through the web interface. After some
> > research, I understand that the primary method for this integration is by
> > using the PyQGIS library, the Python API for QGIS.
> > 
> > 
> > Could you please provide me with some guidance on the following aspects:
> > 
> > 
> > Steps to Integrate PyQGIS with Django: I would greatly appreciate a
> > step-by-step guide or documentation that outlines the process of setting up
> > and integrating PyQGIS with a Django project. This includes installing QGIS,
> > configuring the PyQGIS library, and handling any potential dependencies or
> > issues that may arise during web deployment.
> > 
> > 
> > Best Practices for Web Integration: As I plan to deploy QGIS within a web
> > application, I am concerned about potential challenges related to QGIS's
> > reliance on the GUI. It would be incredibly helpful if you could provide
> > insights or best practices on using QGIS in a "headless" mode to ensure
> > smooth web-based functionality while still accessing the complete range of
> > QGIS features.
> > 
> > 
> > Recommended QGIS API or Alternatives: While I am familiar with PyQGIS, I am
> > open to exploring other QGIS APIs or methods that might better suit web
> > integration. If there are any alternatives or specific QGIS APIs that are
> > more suitable for web-based applications, I would appreciate your expert
> > recommendations and insights on their usage.
> > 
> > 
> > Community Resources: Are there any specific community forums, mailing lists,
> > or documentation repositories where I can connect with other developers who
> > have successfully integrated QGIS with Python and Django in web
> > applications? Being part of a vibrant community of like-minded developers
> > would be invaluable.
> > 
> > 
> > I am enthusiastic about harnessing the power of QGIS in a web environment,
> > and I believe that with your guidance, I can achieve a seamless integration
> > that meets the project's requirements.
> > 
> > 
> > Thank you for your time and support. I am looking forward to your valuable
> > assistance in this endeavor.
> > 
> > 
> > Best regards,
> > 
> > 
> > Pinkal Sanoria
> > Indian
> > 9805637665
> > pinkalsanoria...@gmail.com [pinkalsanoria...@gmail.com]
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osg

Re: [Qgis-user] Add context menu to map canvas

2023-08-02 Thread Ujaval Gandhi via QGIS-User
Put the code block inside initGui(). Tested on a small plugin and worked
fine https://pastebin.com/raw/U55Hbguk
[https://mailtrack.io/trace/link/d204ab4d25292415574deaa5cfbfef567d34b153?url=https%3A%2F%2Fpastebin.com%2Fraw%2FU55Hbguk&userId=8747767&signature=26d638063caac0c3]
---

Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/77965c2ef6002bde576e0b136d4c883ebfebdcaa?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=34ffd88bbade5fae]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Tue, Aug 1, 2023 at 7:47 PM Christoph Jung via QGIS-User
 wrote:

> Hello everyone,
> 
> 
> 
> 
> I try to add a new entry to the map canvas context menu using the following
> two documentations:
> 
> https://docs.qgis.org/3.28/en/docs/pyqgis_developer_cookbook/canvas.html#add-
> items-to-map-canvas-contextual-menu
> [https://docs.qgis.org/3.28/en/docs/pyqgis_developer_cookbook/canvas.html#add-items-to-map-canvas-contextual-menu]
> 
> 
> 
> 
> https://github.com/qgis/QGIS-Documentation/issues/5842
> [https://github.com/qgis/QGIS-Documentation/issues/5842]
> 
> 
> 
> 
> Adding a new menu entry from the python console works like a charm. Now I want
> to provide the context menu through a plugin. But I am not able to connect the
> context menu with a signal declared as a function in the same class, where I
> want to connect it. I receive the message, that my plugin class has no method
> „addMenu“. This is my code snippet:
> 
> 
> 
> 
> from qgis.PyQt.QtWidgets import QMenu
> 
> from qgis.gui import QgsMapMouseEvent
> 
> import json
> 
>  
> 
> class SmallworldShortcutPlugin:
> 
> 
> 
> def __init__(self, iface):
> 
>     self.iface = iface
> 
>     self.canvas = self.iface.mapCanvas()
> 
>         self.canvas.contextMenuAboutToShow.connect(self.populateContextMenu)
> 
> 
> 
> 
> The function populateContextMenu is the same as in the documentation. But if I
> declare the function outside of the class in the same python file, it works
> very well (of course without calling the function on self). Does anybody has a
> hint for me how to connect the map canvas context menu with a function from a
> class? Or is it the right way to declare the function to be connected with the
> context menu outside of a class?
> 
> 
> 
> 
> Best regards,
> 
> Christoph 
> 
> 
> 
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Python Problems

2023-08-01 Thread Ujaval Gandhi via QGIS-User
Looks like it is coming from qgis2web and relates to access to the file you are using. You already received a response to the same query before, so avoid posting the same question again without additional information.---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Tue, Aug 1, 2023 at 9:45 PM John Studley via QGIS-User  wrote:



Dear AllWhy am I getting the following error - how do I resolve it?RegardsJohnAn error has occurred while executing Python code: 
ftplib.error_perm: 550 Requested action not taken. File unavailable (e.g., file not found, no access). 
Traceback (most recent call last):  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\exporter.py", line 321, in cwd_and_create    ftp.cwd(p)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 625, in cwd    return self.voidcmd(cmd)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 286, in voidcmd    return self.voidresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 259, in voidresp    resp = self.getresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 254, in getresp    raise error_perm(resp)ftplib.error_perm: 550 Requested action not taken. File unavailable (e.g., file not found, no access).During handling of the above exception, another exception occurred:Traceback (most recent call last):  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\exporter.py", line 321, in cwd_and_create    ftp.cwd(p)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 625, in cwd    return self.voidcmd(cmd)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 286, in voidcmd    return self.voidresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 259, in voidresp    resp = self.getresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 254, in getresp    raise error_perm(resp)ftplib.error_perm: 550 Requested action not taken. File unavailable (e.g., file not found, no access).During handling of the above exception, another exception occurred:Traceback (most recent call last):  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\exporter.py", line 321, in cwd_and_create    ftp.cwd(p)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 625, in cwd    return self.voidcmd(cmd)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 286, in voidcmd    return self.voidresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 259, in voidresp    resp = self.getresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 254, in getresp    raise error_perm(resp)ftplib.error_perm: 550 Requested action not taken. File unavailable (e.g., file not found, no access).During handling of the above exception, another exception occurred:Traceback (most recent call last):  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\maindialog.py", line 354, in saveMap    result = self.exporter.postProcess(results, feedback=self.feedback)  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\exporter.py", line 330, in postProcess    cwd_and_create(self.remote_folder)  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\exporter.py", line 324, in cwd_and_create    cwd_and_create(parent)  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\exporter.py", line 324, in cwd_and_create    cwd_and_create(parent)  File "C:\Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\qgis2web\exporter.py", line 327, in cwd_and_create    ftp.mkd(base)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 637, in mkd    resp = self.voidcmd('MKD ' + dirname)  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 286, in voidcmd    return self.voidresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 259, in voidresp    resp = self.getresp()  File "C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib\ftplib.py", line 254, in getresp    raise error_perm(resp)ftplib.error_perm: 550 Requested action not taken. File unavailable (e.g., file not found, no access).
Python version: 3.9.5 (tags/v3.9.5:0a7dcbd, May  3 2021, 17:27:52) [MSC v.1928 64 bit (AMD64)] QGIS version: 3.28.8-Firenze Firenze, 5ac45272b5 
Python Path:
C:/PROGRA~1/QGIS32~1.8/apps/qgis-ltr/./python
C:/Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python
C:/Users/Windows/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins
C:/PROGRA~1/QGIS32~1.8/apps/qgis-ltr/./python/plugins
C:\PROGRA~1\QGIS32~1.8\apps\grass\grass82\etc\python
C:\Users\Windows\Documents
C:\Program Files\QGIS 3.28.8\bin\python39.zip
C:\PROGRA~1\QGIS32~1.8\apps\Python39\DLLs
C:\PROGRA~1\QGIS32~1.8\apps\Python39\lib
C:\Program Files\QGIS 3.28.8\bin
C:\PRO

Re: [Qgis-user] Editing expression in QGIS

2023-07-10 Thread Ujaval Gandhi via QGIS-User
You will need to write the expression using QGIS's expression syntax and
functions. There's no direct migration from Excel to QGIS.


You can add a new field using Field Calculator as a 'Virtual Field' which is
computed dynamically, so if any data value changes or you add new rows, the
expression will be evaluated automatically. 
https://docs.qgis.org/3.28/en/docs/user_manual/working_with_vector/attribute_table.html#creating-a-virtual-field
[https://mailtrack.io/trace/link/4ba39305aa20b35528de7fa38a3ec18452d0?url=https%3A%2F%2Fdocs.qgis.org%2F3.28%2Fen%2Fdocs%2Fuser_manual%2Fworking_with_vector%2Fattribute_table.html%23creating-a-virtual-field&userId=8747767&signature=3aa673f10063f979]

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/54638064fd4644a93dec4856f74627dce1b11ca0?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=5d1143e2859dd24d]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Mon, Jul 10, 2023 at 8:28 PM Simon via QGIS-User 
wrote:

> Hi all, 
> 
> 
> Is it possible to add an Excel equation into QGIS via the field calculator in
> the attribute table window. The expression is fairly large, and the references
> will have to be changed but is it even do-able? 
> 
> 
> If not, is there a better tool or plugin I can use?
> 
> 
> The goal is to add the equation, but also to be able to edit it in the future
> if the data changes. 
> 
> 
> Thanks, 
> 
> 
> Simon
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Request for Guidance on Using 'Dissolve' Tool in QGIS with IUCN Data

2023-06-26 Thread Ujaval Gandhi via QGIS-User
There is Vector Geometry --> Aggregate algorithm in the Processing Toolbox
that can summarize values while dissolving features. It can be a little tricky
to use so if you can't figure out how to use it - see my
tutorial https://www.qgistutorials.com/en/docs/3/areal_mean_rainfall.html
[https://mailtrack.io/trace/link/43bf6ee36d437ce2c50d26c89696b2046c0225b5?url=https%3A%2F%2Fwww.qgistutorials.com%2Fen%2Fdocs%2F3%2Fareal_mean_rainfall.html&userId=8747767&signature=d01c47db48ea788d]


Use Field Calculator for updating values using an expression, or just put the
layer in Edit mode, open the Attribute Table and update the values manually. 

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/f80872d1a86e7c96a2818d9f373eff28606b2163?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=88087252a09861e6]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Mon, Jun 26, 2023 at 11:33 AM Bernhard Ströbl via QGIS-User
 wrote:


> Hi Marcello,
> 
> you can choose which fields QGIS should use for the dissolve process. Only
> features that are homogeneous throughout the chosen fields will be dissolved
> into a new feature.
> Hope this helps
> Bernhard
> 
> 
> > Marcello Bilancioni via QGIS-User  [qgis-user@lists.osgeo.org]> hat am 26.06.2023 01:54 CEST geschrieben:
> >
> > 
> > Good morning,
> >
> > I am currently working with the mammal species distribution data provided
> > by IUCN, and analyzing these shape files in QGIS.
> >
> > As part of my analysis, I have been using the 'Dissolve' tool in QGIS to
> > merge rows of the same species into a single entry. This operation is aimed
> > at creating a single comprehensive polygon that represents each species'
> > entire distribution range. However, while the tool successfully
> > consolidates the geometries, it looses important attribute data from the
> > original attribute table. In particular, this leads to the loss of valuable
> > information within the "Presence" and "Origin" columns, where the values
> > can differ across entries for the same species.
> >
> > Could you provide any recommendations on how to avoid such data loss? Is
> > there a strategy or method that could effectively summarize or retain this
> > varied information while processing the data using the 'Dissolve' tool?
> >
> > Furthermore, in my dataset, I have noticed some specific values under the
> > "Presence" and "Origin" columns: "presence 3", "presence 6", and "origin 5"
> > (I have attached a list with those species here). According to the IUCN
> > guidelines, these values need to be updated or adjusted. Do you happen to
> > know how to update these entries within QGIS best?
> >
> > Thank you in advance for any assistance you can provide.
> >
> > Best regards,
> >
> > Marcello Bilancioni
> > ___
> > QGIS-User mailing list
> > QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Adding delimited text layer in QGIS using Geographical modeler- reg

2023-06-25 Thread Ujaval Gandhi via QGIS-User
You can use the “Create points layer from table” algorithm.

On Sun, 25 Jun 2023 at 10:39 PM, Abhi Shek via QGIS-User <
qgis-user@lists.osgeo.org> wrote:

> Hi,
>
> Can you please suggest me how to add a delimited text layer in QGIS using
> Geographical modeler.
> Thanks in advance.
> --
> with warm regards,
> P S N Abhishek,
>
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
-- 
---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] [pyqgis] create new raster

2023-05-09 Thread Ujaval Gandhi via QGIS-User
Instead of manually iterating over the raster, you can use the 'Raster
Calculator' Algorithm to set the pixel values which will be much easier and will
resolve your issues. Test it with the processing toolbox and then all via PyQGIS
with the required parameters.


I tested and the following expression works. Replace N27E086 with the name of
your layer



"N27E086@1"*("N27E086@1"<1500 or "N27E086@1">2000) + -*("N27E086@1">=1500
and "N27E086@1"<=2000)





---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/c359cb3ba6621429914ba43aa93bbeae2d52326f?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=aae92c96b65f2608]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Tue, May 9, 2023 at 11:58 AM andrea antonello via QGIS-User
 wrote:

> Hello,
> 
> I am trying to find out the best workflow to create a new raster.
> As an example I take an existing elevation model raster and loop over it to
> set values between 1500 and 2000 to novalue and write the result to a new
> raster.
> 
> 
> This is the only way I found to do so:
> 
> 
> # create new raster with novalues between 1500 and 2000
> dataType = dtmLayer.dataProvider().dataType(1)
> crs = QgsCoordinateReferenceSystem('EPSG:3003')
> params = {
> 'EXTENT': dtmLayer.extent(),
> 'TARGET_CRS': crs,
> 'PIXEL_SIZE': dtmLayer.rasterUnitsPerPixelX(),
> 'NUMBER': -.0,
> # 'OUTPUT_TYPE': dataType,
> 'OUTPUT': QgsProcessing.TEMPORARY_OUTPUT
> }
> newRaster = processing.run('qgis:createconstantrasterlayer', params)['OUTPUT']
> newRasterLayer = QgsRasterLayer(newRaster, 'temp', 'gdal')
> newRasterProvider = newRasterLayer.dataProvider()
> 
> block = QgsRasterBlock(dataType, cols, rows)
> 
> 
> for row in range(rows):
> for col in range(cols):
> point = dtmLayer.dataProvider().transformCoordinates(QgsPoint(col, row),
> transformType)
> value, res = dtmLayer.dataProvider().sample(QgsPointXY(point.x(), point.y()),
> 1)
> 
> if res and value != -.0:
> if value < 1000 or value > 2000:
> block.setValue(row, col, value)
> 
> 
> newRasterProvider.setEditable(True)
> newRasterProvider.writeBlock(block, band=1)
> newRasterProvider.setEditable(False)
> 
> 
> 
> 
> This code has two main issues:
> 1. if I uncomment the line containing OUTPUT_TYPE, I am getting an error about
> the type passed. But I can't find the right type needed there, it should be
> the one taken from the original provider.
> 2. the resulting raster is scrambled as if there was a shift in the setting of
> the values. But the QgsRasterBlock seems to be built correctly (rows, cols)
> and the values set properly (col, row).
> 3. in the above example, the dtmLayer has an epsg 3033 crs and when loaded
> manually into QGIS, it is recognized. But when I read the layer's metadata crs
> with pyQGIS , it is not able to read it and tells me it is invalid. 
> 
> 
> Has anyone a hint about what I am doing wrong? 
> 
> 
> Thanks,
> Andrea
> 
> 
> 
> 
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] self-learning resources

2023-04-26 Thread Ujaval Gandhi via QGIS-User
Hi Simon,I have a series of beginner-friendly tutorials in multiple languages at https://www.qgistutorials.com/. There's also several full-length courses at https://courses.spatialthoughts.com/---Ujaval GandhiSpatial Thoughtswww.spatialthoughts.comOn Wed, Apr 26, 2023 at 3:59 AM Phil Wyatt via QGIS-User  wrote:Hi Simon,For QGIS I always recommend Locate Press, Discover QGIS 3.0 as it exposes just about everything that folks will come across in early GIS career, plus it has useful exercises and data packages to download.Discover QGIS 3.x Book - Second Edition by Kurt Menkelocatepress.comCheers - Phil, On the road with his iPad On 26 Apr 2023, at 12:20 am, Simon Dietmann via QGIS-User  wrote:







dear group,
 
last week I was asked for a recommendation for resources for self-teaching by an almost complete GIS beginner. Of course I have some ideas, but does anyone of you have the ultimate hint for a good and systematic start
 into GIS in general and/or QGIS ?
 
cheers,
 
Simon
 

i.A. Simon DietmannProjektleiter | Geograph

PGNU Planungsgesellschaft Natur & Umwelt mbHAmtsgericht Frankfurt am Main, HRB 111938; Geschäftsführer: Dr. Benjamin Hill, Johannes Christoph Kress, Alexander von KüchlerHamburger Allee 45 +++ 60486 Frankfurt am MainDurchwahl: +49 69 952964-75 +++ Fax: +49 69 952964-99 +++ Mobil: E-Mail: dietm...@pgnu.de +++ Web: www.pgnu.de> Diese E-Mail könnte vertrauliche und/oder rechtlich geschützte Informationen enthalten. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail sind nicht gestattet.> This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorised copying, disclosure or distribution of the material in this e-mail is strictly forbidden.

___QGIS-User mailing listQGIS-User@lists.osgeo.orgList info: https://lists.osgeo.org/mailman/listinfo/qgis-userUnsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] QGIS under Arch-Linux

2023-02-16 Thread Ujaval Gandhi via QGIS-User
You can try installing using conda. The latest LTR and Current releases are
available on conda-forge


https://www.linkedin.com/posts/alexandre-neto-geo_qgis-activity-7030576968169336832-cwOm
[https://mailtrack.io/trace/link/06cdc2c4ecba275b945832ac4d3faedd2327d6e5?url=https%3A%2F%2Fwww.linkedin.com%2Fposts%2Falexandre-neto-geo_qgis-activity-7030576968169336832-cwOm&userId=8747767&signature=0470f2d3c2e9a56e]



Instructions at
https://gisunchained.wordpress.com/2019/05/29/using-qgis-from-conda/
[https://mailtrack.io/trace/link/da3735f150e424ab9bddb8b1b57cdf3d515721f8?url=https%3A%2F%2Fgisunchained.wordpress.com%2F2019%2F05%2F29%2Fusing-qgis-from-conda%2F&userId=8747767&signature=5a9cf790c9a9f4af]

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
[https://mailtrack.io/trace/link/f15498490707ce09016a3abb50eacfdc7d1f6e3e?url=http%3A%2F%2Fwww.spatialthoughts.com&userId=8747767&signature=a803620488c5babb]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Thu, Feb 16, 2023 at 5:15 AM Nikos Alexandris via QGIS-User
 wrote:


> Hello, is anyone currently using QGIS under Arch-Linux (or else any
> Arch-based distribution)?  I have yet to find a way to make the SIP
> module to be installed/imported properly, and this to obviously make the
> Plugins available.  I have tried without success all available versions
> via AUR, namely :
> 
> - qgis-ltr 3.22.16-1
> - qgis-git 3.99_master.r78162.24a71d05862-1
> - qgis 3.28.3-1
> 
> Any help much appreciated. Kind regards, Nikos
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org [QGIS-User@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Convert an ALOS PALSAR DEM from ellipsoidal to geoid.

2023-01-02 Thread Ujaval Gandhi via QGIS-User
I have a blog post explaining how to do the conversion using GDAL
https://spatialthoughts.com/2019/10/26/convert-between-orthometric-and-ellipsoidal-elevations-using-gdal

On Tue, 3 Jan 2023 at 11:09 AM, Eddison Araya via QGIS-User <
qgis-user@lists.osgeo.org> wrote:

> Hi, thanks, skip previous message, apparently you're right, it's emg96
>
> Thank you
>
> Eddison
>
> [image: image.png]
>
>
>
> El lun, 2 ene 2023 a las 20:08, Eddison Araya ()
> escribió:
>
>>
>> Hello yes, thank you very much, according to that source it is EMG-2008
>>
>> Regards!
>>
>> eddison
>>
>> [image: image.png]
>>
>>
>>
>> El lun, 2 ene 2023 a las 11:16, Nicolas Cadieux (<
>> njacadieux.git...@gmail.com>) escribió:
>>
>>> Hi,
>>>
>>> Will do. I’am heading out of the woods now.  In the mean time, look at
>>> the metadata to find out what ellipsoid is being used by the file.  I
>>> believe it’s probably EMG96 but can you confirm?
>>>
>>> Nicolas Cadieux
>>> https://gitlab.com/njacadieux
>>>
>>> Le 2 janv. 2023 à 08:01, Eddison Araya  a écrit :
>>>
>>> 
>>> Hello Nicolás Cadieux, I hope you had a nice end and beginning of the
>>> year!
>>>
>>> Ok very good, so I await your message with the step by step, just in
>>> case I attach the image:
>>>
>>>
>>>
>>> https://drive.google.com/file/d/1mJvB77MMOF86X7I4qwtS3i7UYq1wYmGR/view?usp=share_link
>>>
>>>
>>> Greetings and thank you very much
>>>
>>> Eddison
>>>
>>>
>>>
>>>
>>> El jue, 29 dic 2022 a las 21:11, Nicolas Cadieux (<
>>> njacadieux.git...@gmail.com>) escribió:
>>>
 Hi,

 Google  vdatum https://vdatum.noaa.gov/   Contact
 me early next year and I can help you step by step.  I can’t help you more
 now because i’am far from civilisation with very limited internet access.

 Nicolas Cadieux
 https://gitlab.com/njacadieux

 Le 28 déc. 2022 à 09:52, Eddison Araya via QGIS-User <
 qgis-user@lists.osgeo.org> a écrit :

 
 Hello, a pleasure to greet you.

 I need to convert an ALOS PALSAR DEM from ellipsoidal to geoid.

 Does anyone know how to do this process step by step?

 Thank you

 Eddison



 ___
 QGIS-User mailing list
 QGIS-User@lists.osgeo.org
 List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
 Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

 ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
-- 
---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] multiple csv file import

2022-11-16 Thread Ujaval Gandhi via Qgis-user
Another option is to use the tool 'Create Points Layer from Table' tool from
QGIS Processing Toolbox. This tool can read a CSV and create a point layer (i.e.
shapefile). First test it on a single file and if it works for your use case,
you can click the 'Run as a Batch Process' and run it on all files in your
folder.


---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com [http://www.spatialthoughts.com]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Wed, Nov 16, 2022 at 3:04 AM Salvatore Mellino via Qgis-user
 wrote:

> I found this on line :
> 
> 
> 
> 
> import glob, os
> 
> # Define path to  directory of your csv files
> path_to_csv = "C:/File Path/"
> 
> # Set current directory to path of csv files
> os.chdir(path_to_csv)  
> # Find each .csv file and load them as vector layers
> for fname in glob.glob("*.csv"):  
> uri ="file:///"+path_to_csv + 
> fname+"encoding=%s&delimiter=%s&xField=%s&yField=%s&crs=%s" % ("UTF-8",",", 
> "Long", "Lat","epsg:4326")
> name=fname.replace('.csv', '')
> lyr = QgsVectorLayer(uri, name, 'delimitedtext')
> QgsProject.instance().addMapLayer(lyr)
> 
> 
> 
> 
> but it doesn’t work. I have csv files with lat long and value separated by 
> space and without header 
> 
> 
> 
> 
> > Il giorno 15 nov 2022, alle ore 21:22, Hugh Kelley  > [hghk...@gmail.com]> ha scritto:
> 
> > 
> > Awesome thanks very much. glad I asked, you learn something new every day.
> > 
> > 
> > On Tue, Nov 15, 2022 at 3:19 PM David Strip  > [qgis-u...@stripfamily.net]> wrote:
> > 
> > > Starting with v2.1, ogr2ogr supports args X_POSSIBLE_NAMES,
> > > Y_POSSIBLE_NAMES which are strings with allowed wildcards (eg, Lon* ), or
> > > you can use field_1, field_2, etc to explicitly give the position of
> > > lat/lon.
> > > It's explained on the driver page.
> > > [https://gdal.org/drivers/vector/csv.html]  This StackExchange
> > > [https://gis.stackexchange.com/a/276607/4449]post shows csv to shapefile
> > > conversion and included Windows command line syntax for looping over files
> > > in a directory.
> > > 
> > > On 11/15/2022 12:58 PM, Hugh Kelley wrote:
> > > 
> > > > David, this was my first thought when i saw this question as well.
> > > > 
> > > > 
> > > > however, I didn't look for very long but I haven't seen a way to tell
> > > > ogr2ogr to read columns in a csv as the lat/lon and write those as
> > > > points to the shapefile.  I generally write a csv to postgres as a
> > > > non-spatial table and then process the lat lon columns with postgis.
> > > > 
> > > > 
> > > > 
> > > >  Are there arguments for ogr2ogr that can do this?
> > 
> > 
> > 
> > --
> > 
> > Hugh Kelley      
> 
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org [Qgis-user@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> [https://lists.osgeo.org/mailman/listinfo/qgis-user]___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Tectonic plate boundaries

2022-08-19 Thread Ujaval Gandhi via Qgis-user
Hi John,


I think you may be working with a 'Line' layer so you can't fill the space
between them. You should get a 'Polygon' layer, specifically the 'PB2002_plates'
from the repository mentioned earlier. You can download it from 
https://github.com/fraxen/tectonicplates/blob/master/GeoJSON/PB2002_plates.json
[https://github.com/fraxen/tectonicplates/blob/master/GeoJSON/PB2002_plates.json]
(right-click and Save As on your computer) and drag and drop it in QGIS.


I also have a detailed step-by-step tutorial that shows how to import and style
data in QGIS, including the tectonic plate boundaries layer that you are
interested in. If you work through the whole exercise, you will have a good idea
how to import several types of data to QGIS and create a
map. https://courses.spatialthoughts.com/introduction-to-qgis#creating-maps
[https://courses.spatialthoughts.com/introduction-to-qgis#creating-maps]

---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com [http://www.spatialthoughts.com]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Fri, Aug 19, 2022 at 3:15 PM John Moyle via Qgis-user
 wrote:

> Thank you one and all with helpful suggestions about finding a shape file of
> tectonic plate boundaries.
> Having tried several of them, QGIS accepts them and allows me to set colour
> type and thickness of line etc but even if they are the only layer selected I
> am unable to see them.  I must be doing something wrong!
> Maybe it's "old dogs and new tricks" at 77 to learn QGIS. The problem is that
> this is probably the only time I will ever be using a GIS and all the courses
> available want to teach so much general GIS before the little bits that I need
> to learn!!  I have my base raster file of the North Atlantic and have learned
> enough to make individual layers of cable interruptions, sub-sea volcanoes and
> land-slides etc. but have come unstuck at an imported shape file!
> Anyway, many thanks one and all.
> 
> 
> Dr John Moyle
> MB, BS, MSc, PhD, CEng, MInstMC, FRCA, FRHistS
> Chartered Engineer
> Physician & Anaesthetist (Retired)
> Historian (Telegraphy & Medical Technology) 
> 
> Home +44(0)1608 665968
> Cell     +44(0)7836 244584
> 
> Amberley
> Cotswold Close
> Tredington
> Shipston on Stour
> Warwickshire
> CV36 4NR, UK 
> 
> "A person has nothing to lose if he believes in God and in the end he turns
> out to be wrong but everything to lose if he wagers that God does not exist
> and it turns out in the end that He really does." - Blaise Pascal (C17th
> French Scientist & Mathematician)
> 
> 
> 
> On Sun, 14 Aug 2022 at 22:35, Fielding, Eric J (US 329A) via Qgis-user
>  wrote:
> 
> 
> > Hi John,
> > 
> > Here is a GitHub site with plate boundaries in several GIS formats,
> > including Shapefile and GeoJSON.
> > https://github.com/fraxen/tectonicplates
> > [https://github.com/fraxen/tectonicplates]
> > 
> > These should work with QGIS. This is from the Bird (2003) paper that is a
> > widely used source of tectonic plate boundaries.
> > 
> > ++Eric
> > --
> > Eric Fielding
> > 
> > eric.j.field...@jpl.nasa.gov [eric.j.field...@jpl.nasa.gov]
> > http://science.jpl.nasa.gov/people/Fielding/
> > [http://science.jpl.nasa.gov/people/Fielding/]
> > Twitter: @EricFielding
> > Jet Propulsion Laboratory
> > Caltech
> > 4800 Oak Grove Drive               
> > Pasadena, CA   91109
> > USA
> > 
> > 
> > 
> > 
> >     Date: Sat, 13 Aug 2022 14:53:54 -0700
> >     From: chris hermansen 
> >     To: John Moyle 
> >     Cc: qgis-user 
> >     Subject: Re: [Qgis-user] Tectonic plate boundaries
> >     Message-ID:
> >          > [fuh6atwa8b5zx1emux9mbv...@mail.gmail.com]>
> >     Content-Type: text/plain; charset="utf-8"
> > 
> >     John and list,
> > 
> >     On Sat, Aug 13, 2022, 09:38 John Moyle via Qgis-user <
> >     qgis-user@lists.osgeo.org [qgis-user@lists.osgeo.org]> wrote:
> > 
> >     > Hi
> >     > New to QGIS. I want to plot Victorian submarine telegraph cable
> >     > interruptions under the Atlantic.  I know, what an Anorak!!
> >     > I have found a brilliant rasterfile of the seabed from GEBCO to use as
> > a
> >     > base layer. I have also collected all the data of cable failure,
> > submarine
> >     > earthquakes and volcanoes and am ready to make vector layers of all
> > the
> >     > data.
> >     > But what I can't find is a shapefile of the tectonic plates
> > boundaries,
> >     > just the boundary lines with no shading or text.
> >     >
> > 
> >     I believe you have a basic misunderstanding of the nature of data within
> > a
> >     GIS.
> > 
> >     Generally the way QGIS (and most GIS) works is they "take" only data
> > such
> >     as points lines and polygons and then the user develops styling on those
> > to
> >     create the desire cartographic effect.
> > 
> >     It would be most unusual to find shading or text in a shapefile.
> > 
> >     Test in a shapefile is an attribute of some geometric feature. So line
> > 377
> >     might have an att

Re: [Qgis-user] [QGIS-Developer] passing parameters to QGIS Python-Script started via Command Line

2022-08-08 Thread Ujaval Gandhi via Qgis-user
One option is to set env variables before launching the qgis command. The env
variables can be read from python.


set QGIS_MESSAGE=Helllo World




Then your myscript.py can be something like


from qgis.utils import iface
import os

message = os.environ['QGIS_MESSAGE']
iface.messageBar().pushMessage(message)





---
Ujaval Gandhi
Spatial Thoughts
www.spatialthoughts.com [http://www.spatialthoughts.com]




[data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACwAAQABAAACAkQBADs=3D]
On Mon, Aug 8, 2022 at 7:52 PM Matthias Kuhn via QGIS-Developer
 wrote:

> Hi Peter,
> 
> 
> You are correct with the analysis of the situation.
> 
> 
> Even if `qgis --help` states the following:
>  [--] treat all following arguments as FILEs
> 
> 
> it does in fact already interpret parameters as files before the `--`
> parameter.
> Changing this behavior is risky (it will break many startup scripts out there)
> and can be considered for QGIS 4.
> For now, we could add another marker as a band aid, e.g. we add a `--ex`
> (extra-parameters) that indicates that any parameters that follow should NOT
> be interpreted as files:
> 
> 
> 
>     qgis -p 1234.qgs --code script.py [files could be here] --ex
> --myparam=1324 -- [more files can still be here]
> 
> 
> If that sounds like what you are looking for, we are happy to help you with
> that
> 
> 
> Best regards
> Matthias
> 
> On Mon, Aug 8, 2022 at 3:55 PM Drexel Peter via QGIS-Developer
>  wrote:
> 
> 
> > Hi everyone,
> > 
> > My goal: I want to open QGIS using the Command-Line, load a specific
> > project, select specific features and zoom to the selected features.
> > 
> > What sounds rather difficult is actually mostly solvable using the
> > following:
> > 
> > "C:\Program Files\QGIS 3.16\bin\qgis-ltr-bin.exe" -p "d:\standardebenen.qgs"
> > --code myscript.py
> > 
> >  
> > 
> > This opens QGIS with the Project d:\standardebenen.qgs and after that it
> > runs the script “myscript.py”.
> > 
> > Within the scrip I can do everything what I can do in a Python-script, so
> > there I can select some features in a layer and show that selection.
> > 
> > But this selections are “hard-coded” in the script, I cannot pass over these
> > parameters to the myscript.py.
> > 
> > In “Pure Python” I can pass parameters to a Python Script using “python
> > myscript.py arg1 arg2 arg3”.
> > 
> > This seems to be not working in the QGIS-Command-Line  as the parameters are
> > interpreted as “layers to load”.
> > 
> > Am I right with my analysis?
> > 
> > One workaround is to write the parameters to al file and use this file
> > within the myscript.py to define the selections. But this is very unhandy…
> > 
> > Are there any ideas from any QGIS-Expert to solve my problem?
> > 
> >  
> > 
> > If this cannot be solved in the current version of QGIS is one of the
> > developers willing to get in contact with me to make an offer the implement
> > this feature ?
> > 
> > Thanks
> > 
> > Peter
> > 
> > ___
> > QGIS-Developer mailing list
> > qgis-develo...@lists.osgeo.org [qgis-develo...@lists.osgeo.org]
> > List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> > [https://lists.osgeo.org/mailman/listinfo/qgis-developer]
> > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> > [https://lists.osgeo.org/mailman/listinfo/qgis-developer]
> 
> 
> https://qfield.org/get/
> [https://ci4.googleusercontent.com/proxy/GqvhkBbIsDNWtqe2HThZLEElIli5211Hog29CYort7mWquajzTRIucqyquJ4nK_KuFTbuEa2CCNNIfLx52nBCCQkb6EWyBAfIjM_iV06dJPuBZpmAolhpdzysf0=s0-d-e1-ft#https://www.opengis.ch/wp-content/uploads/2022/04/Qfield_Banner_email.png]
> [https://qfield.org/get/]
> 
> QFIELD 2.0 IS HERE! - Hold the power of QGIS in your hand - learn more
> [https://www.opengis.ch/2022/04/05/qfield-2-0-is-here/] - get it now
> [https://qfield.org/get]
> 
> ___
> QGIS-Developer mailing list
> qgis-develo...@lists.osgeo.org [qgis-develo...@lists.osgeo.org]
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> [https://lists.osgeo.org/mailman/listinfo/qgis-developer]
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> [https://lists.osgeo.org/mailman/listinfo/qgis-developer]___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] PyQGIS from non-bundled Python install?

2022-06-08 Thread Ujaval Gandhi via Qgis-user
Yes. Configuring system paths to point to qgis libraries will allow native
python to work with pyqgis. I have a complete example for Mac which can be
easily adapted for a linux based system.
https://courses.spatialthoughts.com/pyqgis-in-a-day.html#writing-standalone-python-scripts
[image: Logo] 
Ujaval Gandhi
Spatial Thoughts
mobile: +91-8095684687
email: uja...@spatialthoughts.com
[image: LinkedIn icon]   [image:
Twitter icon] 



On Wed, Jun 8, 2022 at 7:25 AM Andrew Hughes via Qgis-user <
qgis-user@lists.osgeo.org> wrote:

> Hi All,
>
> Q: Is it possible to have a system/native python install work with PyQGIS?
>
> Finer Details: I am working with Azure Functions. Their base
> (container/docker) image includes a python install. I can provide a custom
> docker image, thus I can set system paths and run all the instructions as
> per this https://qgis.org/en/site/forusers/alldownloads.html#debian-ubuntu
> so that QGIS is installed on the container. But, I doubt my (function) app
> can be configured to run a-top of the QGIS python install that is bundled
> with QGIS.
>
> Also, I don't know if conda is an option - would prefer to assume not at
> this point in time as that doesn't align with local development tooling
> that is based on venv.
>
> Things I am hoping to see:
> Yes - but you need to set a PATH or PYTHONPATH
> Yes - but need to see . in requirements.txt
> No - impossible, fill your boots
>
> Thanks for reading
> Andrew
>
>
>
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] add strava heatmap to QGIS

2022-05-11 Thread Ujaval Gandhi via Qgis-user
Hi Hugh,

I made it work successfully in QGIS. The URL needs slight tweaking as
follows

https://heatmap-external-a.strava.com/tiles-auth/all/hot/{z}/{x}/{y}.png?Key-Pair-Id=LONG_STRING

Pro Tip: Use View -> Panels -> Debugging /Development Tools to see the
network request that QGIS is sending out. It helped figure out the correct
url.




On Fri, May 6, 2022 at 9:22 PM Hugh Kelley via Qgis-user <
qgis-user@lists.osgeo.org> wrote:

> Hi,
>
> I'm hoping to add the strava global heatmap as a tile layer in QGIS.
>
> I've done this successfully in the OSM JOSM and ID Editors without a
> problem. this set of instructions/browser plugin is super helpful.
> https://github.com/zekefarwell/josm-strava-heatmap
>
> without sharing my credentials, the url is just:
>
> https://heatmap-external-{switch:a,b,c}.
> strava.com/tiles-auth/all/hot/{zoom}/{x}/{y}.png?Key-Pair-Id=ID_STRING&Policy=VERY_LONG_STRING
> 
>
>
> It seems that I should be able to plug the same url into the QGIS  as an
> xyz layer, but when I do it doesn't work. There's no error or warning, just
> a blank map window. I tried including my strava login in the credentials
> section but this didn't do anything and isn't necessary in the JOSM or ID
> editors.
>
> Just wondering if anyone can think of any further fixes to try or has
> successfully done this themselves. The heatmap api has changed a bit in the
> past couple years so what worked in the past may not work correctly today.
>
> Thanks!
>
> Hugh
>
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] help with shortest-path/network analysis (multiple origins to multiple destinations)

2022-05-06 Thread Ujaval Gandhi via Qgis-user
You need to do Distance Matrix. See
https://www.qgistutorials.com/en/docs/3/origin_destination_matrix.html

On Fri, 6 May 2022 at 7:33 PM, Francesca Parente via Qgis-user <
qgis-user@lists.osgeo.org> wrote:

> Thank you very much indeed Nicolas, for your inputs and all the suggested
> materials!
> I have 50 targets and 532 origins. My goal is to define where is best to
> go within the 50 destinations for each starting point - given the actual
> range of choices though, so I'm not sure that running a batch one-to-many
> would take into account all the variables properly as a many-to-many would
> do. In the absence of a specific modelling, also some second best could
> work.
>
> I understand that your upstream-downstream-Dijkstra script is suitable for
> layer-to-layer indeed and I'm trying to run it, but at the >>> import
> geopandas as gpd<< line I got the following error message:
>
>
>
>
>
>
>
> *Traceback (most recent call last):  File
> "C:\OSGEO4~1\apps\Python37\lib\code.py", line 90, in runcodeexec(code,
> self.locals)  File "", line 1, in   File
> "C:/OSGEO4~1/apps/qgis/./python\qgis\utils.py", line 799, in _importmod
> = _builtin_import(name, globals, locals, fromlist, level)*
> *ModuleNotFoundError: No module named 'geopandas'*
>
> I've been following your tutorial, but I admit I'm not quite familiar with
> py. I've gone through the remaining import coding and it seems working, but
> I'm not sure the "geopandas" module is needed or not to properly complete
> the script.
>
> Thanks again!!
> Best,
> Francesca
>
> Il giorno gio 5 mag 2022 alle ore 22:28 Nicolas Cadieux <
> njacadieux.git...@gmail.com> ha scritto:
>
>> Hi,
>>
>> How many shortest path calculations are you looking at? You could
>> probably do a all pairs shortest path dijkstra and filter the results.  You
>> could batch multiple one to many (point to layers)  In QGIS using the
>> processing plug-in.
>>
>> I did create an algorithm using networkX that could be modified to work
>> with two input layers.  This could be useful if QGIS is not fast enough or
>> if you have too many routes to calculate.  You will find it in the links
>> below. Keep in mind this algorithm was for rivers therefore you have no
>> trafic rules.  This would need more work.
>>
>> You will also find an article we wrote in Data that may help.  If you
>> have trouble with the network, look in the QGIS hub for the models. Look
>> for the 3 “fix directional networks models”.
>>
>> I added a few YouTube videos I made.
>>
>> https://gitlab.com/njacadieux/upstream_downstream_shortests_path_dijkstra
>>   
>>
>> https://www.mdpi.com/2306-5729/5/1/8
>>
>> https://plugins.qgis.org/models/
>>
>> https://youtu.be/v61PafSByvM
>>
>> https://youtu.be/qQrHcKtmr3o
>>
>>
>> Nicolas Cadieux
>> https://gitlab.com/njacadieux
>>
>> Le 5 mai 2022 à 10:38, Francesca Parente via Qgis-user <
>> qgis-user@lists.osgeo.org> a écrit :
>>
>> 
>> Hello everyone,
>>
>> I'd need to identify optimal destinations (within a point layer of
>> geolocated facilities) for each territory of a given set of possible
>> origins.
>> I already calculated a distance matrix between the two point-layers, and
>> also applied the distance-to-nearest-hub tool to generate a string layer
>> and identify the optimal facilities.
>> But I'd like to obtain a more realistic estimate, accounting for the
>> roads network (and ideally their travel times). With quite a few issues, I
>> finally managed to import an OSM road network from download.geofabrik.de
>> (in order to cover my area of interest, I had to merge two different
>> vectors fo Center and Southern Italy and then extract a focus spot in
>> between the two and save it as a lighter layer, otherwise it also took an
>> eternity to run every analysis).
>>
>> So now my question would be: is there a tool to perform a layer-to-layer
>> shortest-path analysis that takes it into account?
>> All that I could find was either point-to-point or
>> layer-to-point/point-to-layer (I looked also at built-in network analysis
>> tool and Qneat3 plugin).
>>
>> Any kind of inputs and suggestions will be more than welcome!
>> Thanks a lot for your support and have a good day,
>> Francesca
>>
>> --
>> 
>> Francesca Parente
>>
>> _ SESS Euro PhD
>>  in
>> SocioEconomic and Statistical Studies
>> _ Luiss SEP  School of European Political Economy
>>
>>
>> email: francescaparente@gmail.com
>>paren...@luiss.it
>>
>> ___
>> Qgis-user mailing list
>> Qgis-user@lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>>
>>
>
> --
> 
> Francesca Parente
>
> _ SESS Euro PhD
>  in
> SocioEconomic and Stati

Re: [Qgis-user] geolocating a list of addresses

2022-03-04 Thread Ujaval Gandhi via Qgis-user
You mention your points are in Lat/Lon but your chosen CRS is UTM. That's
the mismatch.

If your point coordinates are in Latitude Longitude, choose EPSG:4326 WGS84
as your CRS when importing the CSV and it will line up.
[image: Logo] 
Ujaval Gandhi
Spatial Thoughts
mobile: +91-8095684687
email: uja...@spatialthoughts.com
[image: LinkedIn icon]   [image:
Twitter icon] 



On Fri, Mar 4, 2022 at 3:26 PM Francesca Parente <
francescaparente@gmail.com> wrote:

> Hello again and apologies for re-posting on this same thread, I still
> haven't managed to display the points within their polygons.
> I checked the CRS and it's same for both layers: [image: image.png]
> I believe there is an issue with the scale, which I'm not sure how to
> reconcile: when I zoom on the points layer it's 1:14, while with the
> polygons' I see 1:9490547.
>
> Could you please provice any advice on how to solve this?
> Thank you very much indeed for your time,
> Francesca
>
> Il giorno gio 3 mar 2022 alle ore 12:51 Francesca Parente <
> francescaparente@gmail.com> ha scritto:
>
>> Thanks a lot Ujaval, now I see the points displayed!
>>
>> The problem is different than I though then, because it's like this new
>> layer has a different scale with respect to the ones I was already working
>> on... how can I reconcile the two, in order to see the points within the
>> boundaries of related polygons?
>>
>> Thank you so much once again!
>> Francesca
>>
>> Il giorno gio 3 mar 2022 alle ore 12:20 Ujaval Gandhi <
>> uja...@spatialthoughts.com> ha scritto:
>>
>>> Right-click the layer and select 'Zoom to Layer'. If you still do not
>>> see the points, it must be a problem with your CRS or the coordinates
>>> itself. (Make sure Longitude is X field and Latitude is Y field)
>>> [image: Logo] 
>>> Ujaval Gandhi
>>> Spatial Thoughts
>>> mobile: +91-8095684687
>>> email: uja...@spatialthoughts.com
>>> [image: LinkedIn icon]   
>>> [image:
>>> Twitter icon] 
>>>
>>>
>>>
>>> On Thu, Mar 3, 2022 at 4:45 PM Francesca Parente <
>>> francescaparente@gmail.com> wrote:
>>>
 Hello everyone and thank you for making this mailing list available!

 I am using QGIS 3.18 and I have a list of punctual street addresses
 (along with their latitude/longitude data), that I would like to display
 and analyze.
 I've already set a project with polygon layers and related attributes,
 in which the locations should fit.
 I imported the addresses in this project as a delimited text layer
 (specifying the coordinates info in the geometry definition menu), but
 nothing happened next - other than seeing it added to the project layers'
 list.

 I'm not sure on how to proceed further and any advice you may have
 would be so very much appreciated.
 Many thanks for your time and good day to all!
 --
 
 Francesca Parente


 ___
 Qgis-user mailing list
 Qgis-user@lists.osgeo.org
 List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
 Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>>>
>>>
>>
>
> --
> 
> Francesca Parente
>
> _ SESS Euro PhD
>  in
> SocioEconomic and Statistical Studies
> _ Luiss SEP  School of European Political Economy
>
> email: francescaparente@gmail.com
>paren...@luiss.it
>
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user