Description Usage Arguments Details Value Note Author(s) See Also Examples
This function returns the total amount of detected anomaly
clusters under different alpha_lvl
.
1 |
clst_p_values |
a list of matrices. Each matrix has three columns where the first column is clusters starting indexes, second column is the corresponding clusters ending indexes and the third column is the corresponding significant level for clusters. |
alpha_lvl |
significance level for quantifying clusters. |
x |
tested data where the clusters are detected. |
fhat |
a function adjust the distribution misspecification. The default
value is |
dist_null |
a character string giving the underlying distribution in null hypothesis. Distribution options are shown in details. |
... |
further arguments for distribution parameters. |
The dist_null
indicates the underlying distribution class. The options
follow the distributions regular abbreviation in R, Like norm
is normal
distribution, unif
is uniform distribution, gpd
is
generalized pareto distribution.
Distributions
for more distribution options.
This function returns the estimated anomalous amount.
clst_p_values
is not same as the return of hypo_test
.
Corresponding p-values need to be added on the last column.
Zhicong Zhao
F_exp
for estimated expections.
HRR_pt_est
and HRR_sbsp_est
for fhat
estimation.
1 2 3 4 5 6 | ## two clusters with different significant levels
clst_p_values <- list(matrix(c(10,15,0.01,25,30,0.1),nrow = 2,byrow = TRUE))
x <- sort(runif(40))
x <- c(x[1:10],rep(x[10],5),x[11:20],rep(x[20],5),x[21:40])
anom_est(clst_p_values,0.05,x,dist_null = "unif")
anom_est(clst_p_values,0.1,x,dist_null = "unif")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.