Tag Info

New answers tagged

1

Try "STATEFIPS = 1 OR STATEFIPS = 12". Your current expression is effectively "(STATEFIPS = 1) or (12)", and since "12" will always evaluate to true this results in all features being selected.


1

To help with the "proper definition" part of your question; you have looked at https://en.wikipedia.org/wiki/Convex_hull and gotten what could well be considered a "proper" definition but found it lacking, so perhaps a more "useful" definition For every point inside a convex hull, a straight line to any point not within the hull will only intersect the hull ...


2

Vince's comments led me to look again at Shapely in Python, and it can do it. In short, the method I used was: get the bounding box of the page/object you want calculate the diagonal of this box, as this will be the minimum length your hatch lines need to be draw a square array of horizontal lines centred on the bounding box's centre, each spaced suitably ...


2

I think this post in the SAGA GIS forum might prove useful in answering your question about how slope is calculated: https://sourceforge.net/p/saga-gis/discussion/354013/thread/27ecdc6b/ Also, based on my understanding of TWI (as a PhD hydrology student involved in hydrologic modeling), the D-Inf (Tarboton), MFD-md (Qin), DEMON (Costa-Cabral), and MFD ...


3

In case you want to make it go faster by reducing duplicated computations: def CalcIDWvalue(unknowncell, knowncells): weighted_values_sum = 0.0 sum_of_weights = 0.0 neg_half_sens = -sensitivity/2.0 for knowncell in knowncells: weight = ((unknowncell.x-knowncell.x)**2 + (unknowncell.y-knowncell.y)**2)**neg_half_sens ...


4

Awesome, well I found out which parts of the code were wrong and got it to work. I ended up removing two segments in the code that only did some action when the unknowncell and the knowncell were different from each other, which is pointless to test for since that should never be the case. Although obviously it must have had some effect since it managed to ...



Top 50 recent answers are included