R/Period_ts.R

Defines functions Period_ts

Documented in Period_ts

Period_ts <- function(ts)
{
	specvalues <- spec.pgram(ts, taper=0, log='no', plot = FALSE)
	ind <- which.max(specvalues$spec)
	dd <- specvalues$freq[ind]
	return(1/dd)
}

Try the ADTSA package in your browser

Any scripts or data that you put into this service are public.

ADTSA documentation built on May 29, 2024, 11:48 a.m.