spd: Summed probability density (SPD)

View source: R/statistics.R

spdR Documentation

Summed probability density (SPD)

Description

Summed probability density (SPD)

Usage

spd(pdf, normalise = F, xrange, .cutoff = 1e-05, .res = 0.01)

Arguments

pdf

A skyscapeR.pdf object created with either az.pdf or coordtrans

normalise

(Optional) Boolean to control whether to normalize the SPD. Default is FALSE

xrange

(Optional) Array of values (min and max) for SPD if different from range of pdf. If given, it overrides .cutoff

.cutoff

(Optional) Value of SPD at which point it will be cutoff to save on memory. Default is 1e-5

.res

(Optional) Resolution with which to output SPD. Default is 0.01 degrees.

References

Silva, F (2020) A probabilistic framework and significance test for the analysis of structural orientations in skyscape archaeology Journal of Archaeological Science 118, 105138. <doi:10.1016/j.jas.2020.105138>

Examples

# SPD of azimuths
Az <- az.pdf(az=c(87,93,90,110), unc=3)
s1 <- spd(Az)
plot(s1)

# SPD of declinations
hor <- createHor(az=c(0,360), alt=c(0,0), loc=c(35,-8,25)) # flat horizon with 0 degrees of altitude
Dec <- coordtrans(Az, hor)
s2 <- spd(Dec)
plot(s2)

f-silva-archaeo/skyscapeR documentation built on Sept. 24, 2023, 8:14 p.m.