[Qgis-user] 200717 - How do I enclose an orthogonal grid of points with a polygon boundary.

Håvard Tveite havard.tveite at nmbu.no
Fri Jul 17 01:04:19 PDT 2020


Forgot the last step:
5) To get a line layer, run the "Polygons to lines" algorithm
on the output layer from step four.

Håvard

On 17.07.2020 10:00, Håvard Tveite wrote:
> Hi Paul,
> 
> I don't think you will find a function in QGIS to do this,
> but you should be able to achieve it by using the following
> procedure:
> 
> 1) Create a polygon grid with the same "spacing" as your point grid.
> Use the "Create grid" algorithm (from the Processing Toolbox), with
> Grid type: Rectangle (Polygon)
> Grid extent: Click on the ... pull-down and select "Calculate from
> layer", and select your point layer
> Horizontal spacing: 25 meters
> Vertical spacing: 100 meters
> 
> 2) Run the "Join attributes by location (summary)" algorithm with
> Input layer: the generated polygon grid from the first step
> Join layer: your point grid
> Geometric predicate: "intersects"
> 
> 3) Run the algorithm "Select by Attribute" with
> Input layer: your "Joined layer" (from step two)
> Selection attribute: one of the *_count attributes
> Operator: =
> Value: 4
> Modify current selection by: creating new selection
> 
> 4) Run the "Dissolve" algorithm with
> Input layer: your "Joined layer" from step 2-3
> check "Selected features only"
> 
> This should work (but rounding errors may cause problems in
> step two and four)
> 
> Håvard
> 
> On 17.07.2020 07:21, Paul T A Drea wrote:
>> Hello list,
>>
>> I hope this finds everyone safe and healthy during these trying times.
>>
>> I am using a MacBook Pro running macOS 10.15 (Catalina).
>>
>> QGIS version 3.14.0-Pi. QGIS code revision 9f7028fd23.
>>
>> I have a shp file containg 2 653 337 points in an orthononal grid with
>> 25m x 100m spacing of the points.
>>
>> The grid is oriented north south. These points are in lines spaced 25m
>> in the easting (X) direction and 100m northing (Y) direction.
>>
>> I would like to apply a polygon as a boundary (red) as shown in the
>> screen grab below.
>>
>>
>> I have not been able to achieve this using convex hull as the final
>> output does not take into acount the sawtooth steps.
>>
>> Any help or pointers would be appreciated thanks.
>> I am not a coder and have no knowledge of writing any scripts.
>>
>> Thanks and Best regards,
>> Paul
>>
>>
>> -- 
>>
>> */Paul T. A. Drea/*
>>
>> *Geodetic Consultant*
>>
>> *Cell Greece: +30-698 052 0611*
>>
>> *Cell Abu Dhabi: +971 50 595 6547*
>>
>> *Cell U.K.: +44 7507 975162*
>>
>> *SKYPE: paul.drea*
>>
>> *e**-mail 1: **pauldrea at gmail.com* <mailto:pauldrea at gmail.com>
>>
>> *e**-mail 2: **ptadrea at otenet.gr* <mailto:ptadrea at otenet.gr>
>>
> 


More information about the Qgis-user mailing list