7
You can create a new function which returns a percentile value, then, compare the field value.
Open Select Feature by Expression tool
Create new function in the Function Editor using the script below. (How to use the Function Editor)
from qgis.core import *
from qgis.gui import *
import numpy as np
values, layer = None, None
@qgsfunction(args='auto', ...
7
Sure, here some options:
Use the processing toolbox and one of these tools:
Select by Expression
Select by Attribute
Select by Location
Or directly extract them via processing tools:
Extract by Expression
Extract by Attribute
Extract by Location
You can find all of them within "Vector Selection":
Or do it by a manual selection via the ...
5
The user Python functions are stored within the profile directory of your active profile. Under Mac it should be something like ~/Library/Application\Support/QGIS/QGIS3/profiles.
The easiest thing will be use Menu: Settings->User Profiles->Open Active Profile Folder. There you will find a folder /python/expressions where the Python functions are stored....
5
You can use Select by expression and paste this expressions (see also screenshots below):
For the lowest 10%:
"value" <=
array_get(
array_sort (
array_agg ("value")
),
aggregate (
@layer,
'count',
"value"
) / 10 - 1
)
For the highest 10%:
"value" >=
array_get(...
3
If you create GeoJSON layer in Leaflet from GeoJSON file/object, you'll see that each Leaflet feature object gets feature property, which contains source GeoJSON object with all it's properties. If you create GeoJSON object from such layer with .toGeoJSON() method, you get initial GeoJSON object, again with all it's properties.
Taking this into account when ...
3
The short answer
You can solve your problem with two basic tricks:
Create a Print layout
Set a fixed value for scale with data driven override.
In more details:
You can create a new Print layout where you put your map, set extent and scale. When exporting that to an image file, you choose the resolution. The size in pixels will adapt automatically.
The ...
2
Using the generated geojson file, I noticed that it did not open, the name and description being under geometry. I applied the following modification:
var lat = document.getElementById("a").value;
var lng = document.getElementById("b").value;
var name = document.getElementById("c").value;
var description = document....
1
You can use every name you want.
You can open a Dialog from click or you can use the built-in pompt() function.
document.getElementById('export').onclick = function (e) {
// Extractions GeoJson from featureGroup
var geojson = drawnItems.toGeoJSON();
// Stringify the GeoJson
var name = prompt('Enter file name','data.geojson'); // ...
1
The cause could be several things. Without more info, I'd suggest:
[in the standard planimetric QGIS window] digitise a polygon that falls within the footprint of the DEM (can be a temporary layer)
[in the table-of-contents of the qgis2threejs preview window] right-click on the DEM, and click "Clip DEM with polygon layer" in the "Geometry&...
1
Tables are imported as feature but region argument for getDownloadURL() needs a geometry. So replace that line with
'region': table.geometry(),
Link to corrected code.
Side note: getDownloadURL() can be used for obtaining small images only. For large images (such as the whole district or state), please use Export.image.toDrive().
Only top voted, non community-wiki answers of a minimum length are eligible
Related Tags
export × 1271qgis × 378
arcgis-desktop × 266
google-earth-engine × 139
arcpy × 110
pdf × 107
shapefile × 97
raster × 96
arcmap × 79
csv × 58
geotiff-tiff × 55
python × 52
dxf × 41
image × 40
arcgis-10.1 × 39
arcgis-10.0 × 38
arcgis-10.2 × 38
postgis × 36
pyqgis × 36
print-composer × 35
layouts × 34
attribute-table × 32
arcgis-pro × 28
kml × 26
excel × 26