I want to create a lognormal (or other distribution) probability plot in R (for R-studio). I have looked around on the web for an example but none of the examples tell me what package I need to install in order to use the function.
logn_prob_plot <- function()
{
x<-rlnorm(10,5,1)
x
probplot(x,qdist=qlnorm,xlab="failure time",ylab="lognormal probability")
}
Error in probplot(x, qdist = qlnorm, xlab = "failure time", ylab = "lognormal probability") : could not find function "probplot"
Writing up the comment thread as an answer:
The error ( could not find function "probplot"
) is showing up because a necessary package is not installed. It's not specifically related to creating a probability plot.
Googling "r probplot" turns up the documentation for the package e1071
, which is available in CRAN .
The package can be installed by entering install.packages("e1071")
in your terminal or by selecting Tools -> Install Packages
in the RStudio GUI. You can then load that package using library("e1071")
.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.