Last chance! 50% off unlimited learning
Sale ends in
This function calculates the 100*alpha
percent symmetric trimmed mean (0 < alpha
< 0.50), median,
mode, and maximum height of a valid power method pdf, after using pdf_check
. It will stop with
an error if the pdf is invalid. The equations are those from Headrick & Kowalchuk (2007, 10.1080/10629360600605065).
stats_pdf(c, method = c("Fleishman", "Polynomial"), alpha = 0.025, mu = 0,
sigma = 1, lower = -10, upper = 10, sub = 1000)
a vector of constants c0, c1, c2, c3 (if method
= "Fleishman") or c0, c1, c2, c3, c4, c5 (if method
=
"Polynomial"), like that returned by find_constants
the method used to find the constants. "Fleishman" uses Fleishman's third-order polynomial transformation and "Polynomial" uses Headrick's fifth-order transformation.
proportion to be trimmed from the lower and upper ends of the power method pdf (default = 0.025)
mean for the continuous variable (default = 0)
standard deviation for the continuous variable (default = 1)
lower bound for integration of the standard normal variable Z that generates the continuous variable (default = -10)
upper bound for integration (default = 10)
the number of subdivisions to use in the integration; if no result, try increasing sub (requires longer computation time; default = 1000)
A vector with components:
trimmed_mean
the trimmed mean value
median
the median value
mode
the mode value
max_height
the maximum pdf height
Please see references for pdf_check
.
# NOT RUN {
stats_pdf(c = c(0, 1, 0, 0, 0, 0), method = "Polynomial", alpha = 0.025)
# }
# NOT RUN {
# Beta(a = 4, b = 2) Distribution:
con <- find_constants(method = "Polynomial", skews = -0.467707,
skurts = -0.375, fifths = 1.403122,
sixths = -0.426136)$constants
stats_pdf(c = con, method = "Polynomial", alpha = 0.025)
# }
Run the code above in your browser using DataLab