Skip to contents

This intrapolation algorithm replaces internal missing values in a three-dimensional array. For how it works, see the details of intrapolate_2D(). Based on that, intrapolate_3D() does the following:

  • Slice the 3D array into 2D matrices along the rows, columns, and depth dimensions.

  • Use intrapolate_2D() to calculate 2D intrapolations based on the algorithm of intrapolate_1D(). See details in their documentation.

  • In addition, calculate intrapolations along the four directions of 3D diagonals: front northwest to back southeast, that is, front upper left down to back lower right (FNWBSE), FSWBNE, FSEBNW, and FNEBSW.

  • The 3D intrapolation is the mean intrapolation from any of these 2D or 3D values. In taking the mean, missing intrapolations are removed.

  • When there is no intrapolation available from any of the directions, the missing value remains missing.

Usage

intrapolate_3D(ray, consolidate = TRUE)

Arguments

ray

numeric array of three dimensions.

consolidate

logical(1). See return value.

Value

If consolidate = TRUE (default), returns a numeric array of the same dimensions as the input ray with internal missing values linearly intrapolated. If consolidate = FALSE, returns a list of intrapolations for missing values from each slice and diagonal direction.