Description Usage Arguments Value Examples
View source: R/hit_rate_adjusted_from_the_vector_p.R
hit rate adjusted from a vector p
1 | hit_rate_adjusted_from_the_vector_p(p_vector)
|
p_vector |
A vector |
A vector
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | p <- c(1,2,3)
a <- hit_rate_adjusted_from_the_vector_p( p )
a
# [1] -0.25 -1.00 3.00
a[3] == 3
a[2] == p[2]/(1-p[3])
a[1] == p[1]/(1-p[3]-p[2])
#========================================================================================
# application in the function in this package
#========================================================================================
## Not run:
f <- fit_Bayesian_FROC( dataList = d )
e <-rstan::extract(f)
q<-e$p[1,]
hit_rate_adjusted_from_the_vector_p(q)
t(apply(e$p,hit_rate_adjusted_from_the_vector_p,MARGIN = 1))[1,]
q<-e$p[2,]
hit_rate_adjusted_from_the_vector_p(q)
t(apply(e$p,hit_rate_adjusted_from_the_vector_p,MARGIN = 1))[2,]
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.