Get SLGA modelled soil data at a point location.

get_soils_point(
product = NULL,
attribute = NULL,
component = "ALL",
depth = NULL,
poi = NULL,
buff = 0L,
buff_shp = c("square", "circle"),
stat = "median"
)

## Arguments

product Character, one of the options from column 'Short_Name' in slga_product_info, where Type = 'Soil'. Character, one of the options from column 'Code' in slga_attribute_info Character, one of the following: 'VAL' - predicted value surface. 'CLO' - lower 95% confidence interval surface. 'CHI' - upper 95% confidence interval surface. 'CIS' - both confidence interval surfaces. 'ALL' - value and confidence interval surfaces. Defaults to 'ALL'. Integer, a number from 1 to 6. The numbers correspond to the following depth ranges: 0 to 5 cm. 5 to 15 cm. 15 to 30 cm. 30 to 60 cm. 60 to 100 cm. 100 to 200 cm. WGS84 coordinates defining a point of interest. Supply an sf-style point object (length-1 sfg or sfc, or single-row sf data frame) or a length-2 numeric vector (x, y). Length-1 integer. Use if a summarised value around a point is desired. Defaults to 0L, which returns the exact value(s) of the pixel under the poi. A buff value of 1 will return a summary of the pixels in a one-cell range, etc. One of 'square' or 'circle'. Use with buff > 0. Defaults to 'square', in which case all values within the buffer are summarised. A circular mask is applied to the data before summarising otherwise. Summary method applied where buff > 0. Defaults to median. Other options include mean, modal, min, max, sd, IQR, quantile, and summary.

## Value

An data.frame with requested values.

## Note

If you have many points within a relatively small area, it will likely be more efficient to grab a raster covering the whole area and extract summary values yourself.

## Examples

# \donttest{
# get predicted clay value for 60-100cm at a point
clay_pt <- get_soils_point('NAT', 'CLY', 'VAL', 5, c(153,-27.5))

# get the average predicted clay content for 60-100cm within ~300m
avg_clay <- get_soils_point('NAT', 'CLY', 'ALL', 5, c(153, -27.5),
buff = 3, buff_shp = 'circle', stat = 'mean')
# }