LLN_plot: A plot to visualise the law of large numbers

Description Usage Arguments Value

Description

A plot to visualise the law of large numbers

Usage

1
2
3
LLN_plot(.plot = NULL, .true_value = NULL, .indicator_values,
  .m_of_n = NULL, .colours = c("red", "black"), .ltys = c(1, 2),
  .show_text = TRUE, ...)

Arguments

.plot

The plot upon which additional information should be added. A new plot will be created if the default value NULL is used.

.true_value

The true value of the event of interest. The default value NULL can be used to create a plot also in the case this value is unknown.

.indicator_values

A vector with the result of an indicator-function that tells us whether the desired event was observed in the different cases of interest. This could e.g. be related to the result of a coin-toss being head.

.m_of_n

An integer that shows how many of the indicator-values that should be used. This is included in order to enable an animation of the development. The default value NULL will set this argument to be the length of the vector given in .indicator_values.

.colours

A character-vector, default value c("red", "black"), that gives the colour-arguments to be used for the lines showing .indicator_values and .true_value. The second part will be ignored when .true_value=NULL.

.ltys

An integer-valued vector, default value c(1,2), that gives the lty-arguments to be used for the lines showing .indicator_values and .true_value. The second part will be ignored when .true_value=NULL.

.show_text

Logical value, default TRUE that will add the true value given in .true_value (when known) and the estimated value based on .m_of_n and indicator_values.

...

Additional arguments to be used in the xy_sprintf-function.

Value

A plot to visualise the law of large numbers.


LAJordanger/HVLstatistikk documentation built on June 21, 2019, 7:56 p.m.