saller: Feature-based Analysis of a Field (Image)

View source: R/Features.R

sallerR Documentation

Feature-based Analysis of a Field (Image)

Description

Feature-based analysis of a field (image)

Usage

saller(x, d = NULL, distfun = "rdist", ...)

## S3 method for class 'saller'
print(x, ...)

## S3 method for class 'saller'
summary(object, ...)

Arguments

x

saller: x is a list object returned by FeatureFinder or other feature identification function that returns a list with components X.feats, Y.feats (themselves lists with owin class objects defining separate features in the verification and forecast fields, resp.), and X.labeled, Y.labeled (fields with the numbers from 0 to the number of features also defining the separate feature locations (e.g., as returned by the connected function of package spatstat.

print: list object returned by saller.

object

summary: object the returned by saller.

d

(optional) the SAL (saller) method requires division by the longest distance between two border points. If NULL, this is taken to be simply the length of the longest side.

distfun

Function with which to calculate centroid distances. Default uses straight Euclidean. To do great-circle distance, use rdist.earth and be sure that object has a loc attribute with lon/lat coordinates.

...

Optional arguments to distfun. Not used by print or summary.

Details

saller: Computes S, A, and L of the SAL method introduced by Wernli et al. (2008).

Value

saller returns a list with components:

A

numeric giving the amplitude component.

L

numeric giving the lcoation component.

S

numeric giving the structure component.

L1,L2

numeric giving the values that sum together to give L.

L1.alt, L.alt

numeric giving an alternative L1 component, and subsequently alternative L where it is calculated using the centroid of the field containing only defined features rather than the original raw field.

print invisibly returns a named vector with S, A and L.

summary does not return anything.

Note

There are several ways to identify features, and some are provided by this package, but only a few. For example, the method for identifying features in the SAL method as introduced by Wernli et al. (2008) utilizes information from a contour field of a particular variable, and is therefore not currently included in this package. Users are encouraged to write their own such functions, and should feel free to contribute them to this package by contacting the maintainer.

The SAL method typically looks at a small domain, and it is up to the user to set this up before calling these functions, as they are not designed to handle such a situation.

Author(s)

Eric Gilleland

References

Wernli, H., Paulat, M., Hagen, M. and Frei, C. (2008) SAL–A novel quality measure for the verification of quantitative precipitation forecasts. Mon. Wea. Rev., 136, 4470–4487, doi:10.1175/2008MWR2415.1.

See Also

centroid.owin, connected, tiles, tess, deltamm, make.SpatialVx

Examples


data( "ExampleSpatialVxSet" )

x <- ExampleSpatialVxSet$vx
xhat <- ExampleSpatialVxSet$fcst

q <- mean( c(c(x[x>0]),c(xhat[xhat>0])), na.rm=TRUE)

hold <- make.SpatialVx( x, xhat, field.type="contrived", units="none",
    data.name = "Example", obs.name = "x", model.name = "xhat" )

hold2 <- FeatureFinder(hold, smoothpar=5, thresh=q)
## Not run: plot(hold2)

look <- saller(hold2)   
summary(look)



SpatialVx documentation built on Nov. 10, 2022, 5:56 p.m.