expt.plot {clttools}R Documentation

Theoretical Probability Distribution Plot of General Experiment

Description

General experiment plot with basic probability

Usage

expt.plot(x, n, prob = NULL, col = "black", type = NULL,
main = NULL, sub = NULL)

Arguments

x

vector, possible outcomes in one trial of experiment

n

number of trials

prob

probability assigned to each possible outcome

col

color of the plot

type

type of plot

main

an overall title for the plot

sub

a sub title for the plot

Details

The default probabilty equals to 1/n. All the assigned probabilites must between 0 and 1.

Value

Plot of mean value and corresponding probabilities for all possible outcomes.

Examples

expt.plot(x = c(1:3), n = 4, col ='red', type = 'p')
expt.plot(c(2:4), 3, prob = c(0.3, 0.5, 0.2))

[Package clttools version 1.3 Index]