5

I have a points vector layer. I'd like to increase the point density by adding new points in between the existing points. The new points should have the interpolated value, in between the value of the nearest old points.

See below, the existing points are in orange, the desired new points grid density is in green.

Old Points-Orange. Desired new points-Green

I tried interpolation with IDW, or Voronoi methods, but both are not designed to do this task.

Are there other processing tools to do it?

I'm using QGIS 3.34. The layer's CRS is WGS 84.

The points are regularly placed vertically and horizontally N/S E/W and spaced 0.25° each.

I created this layer sampling a raster layer that had the same resolution.

As the idea is to double the resolution of the points layer, the new layer should have the points spaced with 0.125°. The new layer should have the same extent of the old layer (in the image I draw only a few green dots)

4
  • 1
    Writing a simple filter that takes the old layer in vector space and populates a new one shouldn't be too difficult. You do need to choose how to handle the center point, since it could have conflicting interpolation E/W and N/S. Please Edit the question to state how the points were created, and the orientation angle between point rows/cols and the coordinate system. If they're aligned with the axis, then converting the points to raster, resampling with a bilinear or cubic convolution, then converting back to vector should be enough (though it may change the original point values. Commented Oct 14, 2025 at 12:04
  • 2
    IDW can do this, or at least it can do the second part. This is really two questions, how can I generate a densified grid given a set of points, and how can I interpolate values on a set of prediction points (your new grid) given the values at a set of other points (this is what IDW can do, as can kriging and any of several other smoothing methods depending on your application) Commented Oct 14, 2025 at 12:15
  • You want a new ("green") point between every yellow point, yes? You've only shown a few in your image. Commented Oct 14, 2025 at 12:16
  • Thank you. I edited the question. Your answers guided me to solve the task. Commented Oct 14, 2025 at 13:14

2 Answers 2

7

I solved it as follows:

  1. Create a new raster layer with TIN interpolation as @Bera suggested. The resolution of the new layer is 0.25°/9 = 0.0277°. I did this because increasing the resolution to 0,125° (twice the previous, 0,25°), or any other even division of the original distance, had the conflict of the point in the center as @Vince said.
  2. Create a new regular points layer of 0.125° and sample the raster values.

It actually was with two steps as @Spacedman said.

All the i) old points layer in orange, ii) the interpolated layer and iii) the new regular points layer in green involved in the problem and solution are shown in the image below.

problem solved

4

You could do it without creating a raster, only vector-based:

  1. Create a new point grid with the extent of the initial grid, but a fraction of the distance.

  2. Create an array of the values of closest points:

  • 1 closest point for those that fall exactly on the points of the old grid

  • 2 closest points for those that fall exactly in between two points of the old grid

  • 4 closest points (neighbours) for those that are in the middle (diagonal) of for points of the old grid.

    To do so, use the expression below. It tests 3 cases: if there is a point very close (distance < 0.0001, thus identical point), than it takes the value from there. If there are points in a distance slightly larger (again, to consider rounding issues) than the new grid's interval, two points are considered, in any other case, 4 neighbours are taken into consideration. In the expression, replace grid_old with your layername of the initial point grid, value with the name of the attribute you want to interpolate and 54 is a bit above the distance between new points (grid interval of 50).

    case 
    when
        overlay_nearest ('grid_old', max_distance:=0.0001)
    then
        overlay_nearest ('grid_old', value)
    else
        if (
            overlay_nearest ('grid_old', max_distance:=54),
            overlay_nearest ('grid_old', value, limit:=2),
            overlay_nearest ('grid_old', value, limit:=4)
        )
    end
    

    You could modify the expression to include more/less neighbouring points to take into consideration, as you wish.

  1. Now, calculate the interpolated value from this array, e.g. using array_mean() to get the mean value. You could use QGIS expression to calculate any other value (interpolation method).

Blue labels are dynamically created, based on the expression above with array_mean():

enter image description here

3
  • Thank you. Originally I was seeking for a vector-based approach. Commented Oct 14, 2025 at 15:34
  • Should I paste directly the expression, with the adjustments you mentioned, in the Function Editor from the Field Calculator? Asking as I get this error: File "", line 3 overlay_nearest ('CDD_VHIS-RA', max_distance:=0.0001) IndentationError: unexpected indent Commented Oct 14, 2025 at 15:43
  • 1
    Yes, directly insert the expression to the Field Calculator's Expression Editor - not the Function editor. Commented Oct 14, 2025 at 16:13

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.