Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

getLabel

Labels for distribution objects


Description

a help function to get reasonable labels for distribution objects

Usage

getLabel(x, withnames = TRUE)

Arguments

x

a distribution object

withnames

logical: are the parameters (if any) of x to be displayed with names?

Remark

The need for this helper function (external to our plot methods) was brought to our attention in a mail by Kouros Owzar owzar001@mc.duke.edu.

Author(s)

See Also

Examples

## example due to Kouros Owzar:
foo<- function(law,n, withnames = TRUE)
  {
    data.frame(muhat=mean(r(law)(n)),n=n,law= getLabel(law,withnames))
  } 
### a function that groups certain informations on 
##  created with distribution objects
do.call("rbind",lapply(list(Exp(1),Norm(0,1),Weibull(1,1)),foo,n=100))
do.call("rbind",lapply(list(Exp(1),Norm(0,1),Weibull(1,1)),foo,n=100,FALSE))

distr

Object Oriented Implementation of Distributions

v2.8.0
LGPL-3
Authors
Florian Camphausen [ctb] (contributed as student in the initial phase --2005), Matthias Kohl [aut, cph], Peter Ruckdeschel [cre, cph], Thomas Stabla [ctb] (contributed as student in the initial phase --2005), R Core Team [ctb, cph] (for source file ks.c/ routines 'pKS2' and 'pKolmogorov2x')
Initial release
2019-03-11

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.