penaltyPrint: Show a table of all penalties taken by or against a men's...

Description Usage Arguments Value Author(s) See Also Examples

View source: R/penaltyPrint.R

Description

Search for a player – either exact match or using fixed regular expressions – and return all penalties taken by or against this player as table.

Usage

1
penaltyPrint(player, goalkeeper = TRUE, exact = TRUE, pendat, includeMisses = TRUE)

Arguments

player

Character vector of length 1 which contains the full name of a player in pendat or a part thereof.

goalkeeper

Boolean, specifies whether player is searched for among goalkeepers (TRUE) or penalty takers (FALSE).

exact

Boolean, specifies whether to look for an exact match. If set to FALSE, grep(player, fixed = TRUE) is used to search for the player.

pendat

Name of a data set containing the penalties. The data set needs to follow the format of penalties.

includeMisses

Boolean, indicates whether to include penalties that missed the goal without the goalkeeper actively saving the ball.

Value

Returns a data.frame that is a subset of pendat.

Author(s)

Leo N. Geppert

See Also

penaltyPlot

Examples

1
2
3
data(penalties)
penaltyPrint('Illgner, Bodo', pendat = penalties)
penaltyPrint('Illgner', exact = FALSE, pendat = penalties)

footballpenaltiesBL documentation built on March 17, 2021, 5:07 p.m.