sphscore: Calculate Spherical Scores

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

Calculate spherical scores and average spherical scores by a grouping variable.

Usage

1
sphscore(object, data, group = NULL, bounds = NULL, reverse = FALSE)

Arguments

object

an object of class "formula", of the form outcome ~ forecast. See calcscore() documentation for further details.

data

an optional data frame or list containing the variables in the formula. If not found in data, the variables are taken from the environment from which calcscore is called.

group

the name of a grouping variable within data, which is used to calculate average spherical score by group.

bounds

a vector of length 2 corresponding to the desired minimum and maximum spherical score, respectively.

reverse

if FALSE (default), smaller scores imply better forecasts. If TRUE, larger scores imply better forecasts.

Details

If group is supplied, the function returns a list (see value section). Otherwise, the function returns a numeric vector containing the spherical score associated with each forecast.

Value

Depending on input arguments, sphscore may return an object of class numeric containing raw spherical scores. It may also return a list containing the objects below.

rawscores

an object of class numeric containing raw spherical scores for each forecast.

mnsph

an object of class numeric containing mean spherical scores for each unique value of group.

Author(s)

Ed Merkle

References

Toda, M. (1963). Measurement of subjective probability distributions. ESD-TDR-63-407, Decision Sciences Laboratory, L. G. Hanscom Field, Bedford, Mass.

Shuford, E. H., Albert, A., & Massengill, H. E. (1966). Admissible probability measurement procedures. Psychometrika, 31, 125-145.

See Also

calcscore

Examples

1
2
3
4
5
6
data("WorldEvents")
## Raw spherical scores
sph1 <- sphscore(answer ~ forecast, data=WorldEvents)
## Raw spherical scores plus group means
sph2 <- sphscore(answer ~ forecast, data=WorldEvents,
                 group="forecaster")

Example output



scoring documentation built on May 2, 2019, 4:53 p.m.

Related to sphscore in scoring...