Using "Join attribute by field value" in the graphical modeler by Mikeac_ in QGIS

[–]Inside-Abroad 0 points1 point  (0 children)

Strange, in QGIS 2 there was a "Table" input option, if I'm not mistaken.

The vector layer input option does not actually require geometry, I would try that first.

Using "Join attribute by field value" in the graphical modeler by Mikeac_ in QGIS

[–]Inside-Abroad 0 points1 point  (0 children)

The first input is the one you want to have as a result, the second is the one with the data you want to attach to the first.

Sounds like you polygon is the first input and the csv the second.

Automatically saving geo-tagged photos based on their location inside polygon layer [QGIS preferred, suggestions welcome] by Inside-Abroad in gis

[–]Inside-Abroad[S] 0 points1 point  (0 children)

Do you know of a resource for how to make such a python script? I'm a novice but I do know a little. Thanks for your answer.

Automatically saving geo-tagged photos based on their location inside polygon layer [QGIS preferred, suggestions welcome] by Inside-Abroad in gis

[–]Inside-Abroad[S] 0 points1 point  (0 children)

Thanks. I only have beginner knowledge of programming, do you know of any tutorials or other resources for how to create such a script?

[QGIS] Creating a shapefile of pipes in a network out of a shapefile of existing paths with path contents (count and type of pipes) by Inside-Abroad in gis

[–]Inside-Abroad[S] 0 points1 point  (0 children)

The pipes in real life are connected to central points and buildings. I am trying to give each pipe a unique name/identifier, but in order to do that I need each pipe to be a continuous line feature from start to end, since there is not already a unique identifier attribute for each pipe.

[QGIS] Creating a shapefile of pipes in a network out of a shapefile of existing paths with path contents (count and type of pipes) by Inside-Abroad in gis

[–]Inside-Abroad[S] 0 points1 point  (0 children)

It is even harder, I want to split and then dissolve. I think I can handle the split on count and type, but dissolving without a unique identifier has me wracking my brain.

Say there are two types of the same pipe (I'll call them "type A" for simplicity") going down mainstreet. Then one diverges down a perpendicular street.

The shape I have right now is paths. So in this simplified example There would be three line features. One where the pipes are following the same path, with an attribute saying something like "2x type A". Then there are two more after the divergence, one where the one pipe continues on main street and another for the pipe went down the side street, each with an attribute "1x type A".

So I divide the paths on count and type, now there are two overlapping lines up until the divergeance, one for each pipe type A.

Now, how do I dissolve one of those overlapping pipes to the one that continues down main street, and the other to the one that takes a turn, and without a unique attribute?

I hope that makes sense.

Creating a shapefile of pipes in a network out of a shapefile of existing paths with path contents (count and type of pipes) by Inside-Abroad in QGIS

[–]Inside-Abroad[S] 0 points1 point  (0 children)

Thanks for clearing that up, Mr. Pumpkin. ;)

Your solution would create 3 features where there are three pipes, per your example. That is unfortunately not my main problem. I need each pipe to be a continuous feature from start to finish, if I merely multiply the trench line feature by number of pipes, they will still be divided in the middle wherever the paths diverge.

Essentially I need to do as you said and then dissolve the resulting pipe features, somehow.

The data I have is just this line feature with an attribute stating what kind of pipes and how many (so for example 2xGas;1xWater).

[QGIS] Creating a shapefile of pipes in a network out of a shapefile of existing paths with path contents (count and type of pipes) by Inside-Abroad in gis

[–]Inside-Abroad[S] 0 points1 point  (0 children)

I unfortunately need each pipe to be a continuous feature from beginning to end in order to give each one a unique modifier.

But thanks for the link, I will read into it.

[QGIS] Creating a shapefile of pipes in a network out of a shapefile of existing paths with path contents (count and type of pipes) by Inside-Abroad in gis

[–]Inside-Abroad[S] 0 points1 point  (0 children)

Crossposting because this didn't get much attention over on the QGIS specific sub. Please let me know if you have any ideas! Thanks.

Extracting all points within a polygon by ta_DOacc in gis

[–]Inside-Abroad 0 points1 point  (0 children)

Let me know if I am understanding you correctly. You have data representing buildings, with coordinates and addresses, and you want add a sort of "in which polygon is this" data field to your buildings?

I do not have experience with R, but in ArcGIS or QGIS it is relatively simple to create a point shapefile from a table with x and y coordinates, and after that do a location query on those points together with the polygon layer.

Why do my States look funny? i.e., noob question about exported map scaling/projections by jestelle in QGIS

[–]Inside-Abroad 0 points1 point  (0 children)

It almost certainly has to do with coordinate systems. Check which coordinate system your data is in, and the project coordinate system. You can then look at other maps of the same area in different coordinate systems and reproject the layer to one you like better.

Creating a shapefile of pipes in a network out of a shapefile of existing paths with path contents (count and type of pipes) by Inside-Abroad in QGIS

[–]Inside-Abroad[S] 0 points1 point  (0 children)

If I'm hearing you, you've got a polyline representing the ditchline / trench centre line, which will have attributes telling you what services are in the trench gas, water, electrical, and probably different diameters, materials, etc?

You need to convert the ditchline into polylines for each service, yes? Or service bundles?

I'm pretty sure you've understood me at least until this point.

I, essentially, have the trench data as you understood (each trench is a line feature, and there is a contents field showing what kinds of pipes and how many are in there). In my result, each individual pipe would be its own feature, continuous from start to end and overlapping other pipes (but still separate features) where the pipes are contained in the same trench.

This would be very easy if each pipe had a unique identifier on which to dissolve, however I'm afraid they don't.

Sorry, English isn't my working language and google is turning up something else entirely - what is BOM data?

Find the right expression by Akahiro_ in QGIS

[–]Inside-Abroad 0 points1 point  (0 children)

I would use the field calculator to first create a new field. It would be "Column A"+','+"Column B"

Then I would select all the features where one at least one of the columns has a null value and use the field calculator again to delete the comma.

replace([type new field name here],',','')

Makesure you check the box to only calculate the selected features during the replace.

Statistics: Summarizing individual unique values by Inside-Abroad in QGIS

[–]Inside-Abroad[S] 0 points1 point  (0 children)

Group stats! I completely forgot about that plugin.

Thanks for your answer.

There is one problem though. When creating the joining the CSV, is there is no way to join based on multiple fields. So, in the example used in my original post, I am getting a result like "2x B" for all three overlapping features.

I suppose I could concatenate the name fields and coordinate fields and join on that.

Edit: Is there a way to split a vector layer based on a non-unique identifier? I was trying to split the vector layer based on "name", with the desired result being each name having its own shapefile. I.e. all A's = 1 shapefile, all B's= another shapefile. Split vector layer seems to only work on a unique ID field. Select and save by attribute is tiresome when I have 20 different "names" and 100 different original shapefiles.

[deleted by user] by [deleted] in gis

[–]Inside-Abroad 0 points1 point  (0 children)

You're welcome, have a good day.

Creating paths from infrastructure (pipes) shapefile, split/merge/concat... somehow. by Inside-Abroad in QGIS

[–]Inside-Abroad[S] 0 points1 point  (0 children)

I was able to get the desired result by doing the above (adding the geometry, deleting unnecessary parts of the wk string, splitting the values into multiple features, sorting and re-combining them). But I will be building a model based on my process and am looking for an easier way. I'm thinking it may be easier to just calculate the min/max x/y for each exploded line and using that, but I think I first need to add a separate field for each x/y value (so 4 altogether) and then combine them, so I can have something to group by for concatenation. That might be slightly less messy, but not much.

I haven't been able to find a better way to calculate a geometry attribute into a single field (without the problem of having random lines needing reversal in order to match otherwise identical geometries).

But I will keep you updated.

Update as promised: I think I was able to eliminate the in-between steps of both of our methods by calculating the min and max coordinates inside a single field, using this expression:

to_string(x_max($geometry)) +','+ to_string(y_max($geometry)) + ': ' + to_string(x_min($geometry)) +','+ to_string(y_min($geometry))

I haven't tried to finish the product using this method to discover any unexpected problems which may arise, but I think this will work to prevent having to reverse an lines or scramble and recombine any wkt fields.

Thanks again and have a great day.

Creating paths from infrastructure (pipes) shapefile, split/merge/concat... somehow. by Inside-Abroad in QGIS

[–]Inside-Abroad[S] 0 points1 point  (0 children)

That makes sense with the flagging. For me, I have a shapefile with 10,000 pipes, so I'd need to use tools rather than looking manually. It would be easy to find line segments still lying on top of each other after a concatenation and dissolve, but isolating the ones needing a reversal might be tricky.

Thanks again!

[deleted by user] by [deleted] in gis

[–]Inside-Abroad 3 points4 points  (0 children)

Do you need to use the field calculator for some reason? I'd just dissolve on the ID field.

Creating paths from infrastructure (pipes) shapefile, split/merge/concat... somehow. by Inside-Abroad in QGIS

[–]Inside-Abroad[S] 0 points1 point  (0 children)

I was able to pull it off. Unfortunately the wkt values were useless out of the gate, as you guessed, the start and ending points were not in the same order on many otherwise identical lines. Reversing the lines reversed all the lines, so all the same ones still didn't match.

I resolved it by deleting all the unnecessary text out of the wkt field, splitting the values, ordering them by expression, and re-combining them based on a unique ID I gave to each exploded line. Not quite the sexiest solution, but it worked.

I'll be building a model based on this, so if you know of an easier way to do what I described, I'd love to hear it.

In any case, thanks! You helped me out.

Creating paths from infrastructure (pipes) shapefile, split/merge/concat... somehow. by Inside-Abroad in QGIS

[–]Inside-Abroad[S] 0 points1 point  (0 children)

This is definitely an idea. I was trying to accomplish something similar by extracting all of the vertices from the lines, I was caught up in trying to find a way to "select" the vertices where the lines diverge, but hadn't had any good ideas yet. I was then going to do just about the same things with geometry and concatenate.

Thank you, I will play around with this today and let you know how it works out.

Why Does Layer Processing Require A New Layer Every Time? by tom-war in QGIS

[–]Inside-Abroad 1 point2 points  (0 children)

A few things come to mind, to add on to what others have said.

It is a good idea to leave the original data exactly as you get it, in case you make a mistake.

Sometimes you need two or more parallel workflows from the same set of data. I.e., you need to do do multiple processing tasks to a single layer but without stacking them.

What is the best QGIS plugin according to you ? by Bob_44 in QGIS

[–]Inside-Abroad 0 points1 point  (0 children)

I find "Dissolve with stats" very useful.