select_door: Player selects a door

Description Usage Arguments Details Value Examples

View source: R/Monty Hall Script.R

Description

This function creates a numeric vector of length one. This vector represents the door that the player selected and is either 1, 2, or 3.

Usage

1

Arguments

...

This function does not take any arguments

Details

The door is selected at random using sample() and will represent the either a goat or car based on the positions in a.game

Value

This function returns a numeric vector of length one called a.pick

Examples

1

dlyork/montyhall documentation built on Jan. 31, 2021, 7:22 p.m.