17
votes
Plotting map resulted from kriging in R
In order to interpolate prices with kriging you first need to convert your geographic coordinates to projected coordinates. Assuming you have them, below there is a reproducible example, showing a way ...
17
votes
Accepted
R gstat krige() - Covariance matrix singular at location [5.88,47.4,0]: skipping
This error is commonly returned because you have duplicate locations. You can check this using the sp::zerodist function.
To remove duplicate locations you call sp::zerodist within a bracket index.
...
11
votes
Accepted
Improve performance of a PostGIS st_dwithin query
The explain doesn't show an index coming into play, which could be for two reasons:
You don't have one. So make one with CREATE INDEX tree_gix ON trees USING GIST (geom)
Your data is in geographic ...
10
votes
Accepted
Performing Kriging in QGIS
The great thing about QGIS is its modular design, based on which you can use the geoprocessing engines of various other systems directly as tools in QGIS (GRASS, SAGA, GDAL, OGR, ...). In order to do ...
10
votes
Which interpolation technique is suitable for a bathymetry of a small lake?
One alternative is spline interpolation as suggested in the related post:
Interpolation of multibeam bathymetry.
From QGIS, use the GRASS tool v.surf.rst:
Performs surface interpolation from ...
10
votes
Accepted
Replica of point layer data from attribute value in QGIS
The following script does the job:
layer = QgsProject.instance().mapLayersByName('Layer_Name')[0]
name_field = 'Name' # not mandatory
count_field = 'Count' # numerical field, mandatory
# make new ...
9
votes
Accepted
QGIS: what is the difference between heatmaps and interpolation plugins?
Heatmaps and interpolations are completely different things though they might look similar.
A heatmap visualizes "hotspots" in the distribution of features on the map i.e. dense areas will be ...
8
votes
Performing Spline interpolation on GPS Track
Try using v.generalize tool from the Processing Toolbox. There are a number of algorithms in there that can generalize a line nicely.
Another possible solution could be the "Generalizer" ...
8
votes
Downscaling raster images in Google Earth Engine?
You can control the pixel size of an image by setting the scale parameter of ee.Image.reproject():
// Reference a Landsat scene.
var image_30m = ee.Image('LANDSAT/LC08/C01/T1/LC08_044034_20170614');
...
8
votes
Interpolate smoothly nodata values in QGIS
I got curious and tried the different fill nodata functions. As you can see the regular SAGA Close Gaps produced the least anomalies. It also took the longest.
8
votes
Accepted
How to use GDALGridInverseDistanceToAPower in a python script
Yes, you can call this from a Python script. But you don't directly call the low-level C API.
First, take a look at the GDAL Grid Tutorial for background info. From the Python library, the relevant ...
7
votes
Accepted
Interpolating degree data using QGIS?
Interpolate the sine and cosine of the angle, and then convert back to an angle with the atan function. These functions are available in QGIS' expression engine. There is an atan2(dy,dx) function like ...
7
votes
Accepted
How to calculate kriging weights?
Is it true that we're just using a different set of weight values than the 1/distance in IDW?
Yes, both IDW interpolation and Ordinary Kriging (OK) will calculate weights based on distance, but with ...
7
votes
Accepted
Smoothing/interpolating across images in an ImageCollection to remove missing data
You can replace the values using where().
// Replace masked pixels by the mean of the previous and next months
// (otherwise, how to deal with the first images??)
var replacedVals = composites.map(...
7
votes
PostGIS: Interpolate/Cluster geographic points to average points
A solution using PostGIS alone.
The Steps are as follows:
Generate clusters from the points
Get the centre of each point cluster
Generate a line that connects each cluster centre point (will also ...
7
votes
Accepted
Interpolating series of points between two locations using Python
A simple linear interpolation solution
This solution generates N-number of random points lying on a straight line between two initial locations. Initial latitude and longitude were transformed to x ...
7
votes
Accepted
Interpolation on grid using QGIS
The solution: the principles
You can do this creating an interpolated raster out of the points and then get the raster (pixel) value inside of each cell. There are several raster interpolation methods ...
7
votes
Using gdal to interpolate elevation from a GeoTIFF
A high-level rasterstats tool is built on GDAL to fetch data from raster and vector data sources.
import rasterstats
from shapely.geometry import Point
raster = "elevation.tif"
pt = Point(...
6
votes
Accepted
Raster interpolation with gdalwarp, and replicating with python API
You have now a better way to do.
Since RFC 59.1 : GDAL/OGR utilities as a library, you can use gdalwarp from Python directly without using any call to the command line utility but using really the ...
6
votes
Weird output when projecting/interpolating points on lines
I think you have a problem with your points shapefile and/or the projections (lines and points).
These commands are those of Shapely used by GeoPandas
From Coordinate of the closest point on a line
...
6
votes
TIN Interpolation plugin in QGIS 3.0
According to the changelog, the TIN interpolation plugin has been removed, as it is now part or QGIS core.
To find it in Qgis 3.0, open the processing toolbox and search for Interpolation -> TIN ...
6
votes
Accepted
Interpolation with 10 data points
Both methods are "appropriate".
IDW basically says "half way between a point valued 6 and a point valued 8 the value is going to be 7", but extended to the distance to multiple ...
5
votes
What resampling technique should be used when projecting aerial photos?
The previous answers are correct when you truly wish to RESAMPLE your data, such as if you are aggregating your data from a 30 m pixel size to a 90m pixel size. In this case you are attempting to ...
5
votes
How to compute an interpolation raster from the python console in QGIS?
The documentation on pyqgis is not very self-explanatory, but i figured out how to properly call the associated interpolation classes (QgsInterpolator, QgsTINInterpolator, QgsIDWInterpolator, ...
5
votes
Using kriging to extrapolate values outside of sampling polygon in ArcMap?
Following a bit on what Jeffrey Evans said, you must remember that your data points define an area that's called convex hull. It is the (convex) polygon of minimum area that contains your data points.
...
5
votes
Accepted
Creating SpatialPolygons in R
You are confusing terms and thus, confusing us. The expected input for kriging prediction in the gstat krige function is a systematic array of points and not polygons. It would also be nice if you ...
5
votes
Accepted
Error in In predict.gstat in R
As I pointed out, you had identical observations. Additionally, you were not using the "resolution" argument in the raster function so, were only creating 100 pixel observations to predict to. I had ...
5
votes
Slope layer with false results in QGIS?
As mentioned in comments by user30184 and GerardoJimenez this is due to the horizontal coordinates x and y having a different unit of measurement from the elevation coordinate z.
For example, having ...
5
votes
How to interpolate a lat/long point between two others at a given distance
The name of the curve you are looking to interpolate along is called either a great circle for a sphere, or a geodesic for an earth-shaped ellipsoid of revolution.
Using GeographicLib, you can create ...
5
votes
How to calculate kriging weights?
Maybe I should begin by stating that "the summit issue is reflecting how IDW models the surface, rather than weighting". IDW sees the predicted surface as an averaging model, while Spline tries to ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
interpolation × 894qgis × 261
arcgis-desktop × 203
raster × 161
kriging × 118
r × 104
inverse-distance-weighted × 67
python × 65
spatial-analyst × 53
dem × 50
arcmap × 44
point × 42
spatial-statistics × 42
tin × 31
gdal × 30
geostatistical-analyst × 26
grass-gis × 25
postgis × 23
arcgis-10.0 × 23
spline × 23
arcgis-pro × 22
saga × 22
contour × 22
gstat × 20
lidar × 19