Learn R Programming

mlbstats (version 0.1.0)

rp: Calculates runs produced

Description

Computes the number of runs contributed by a hitter, based on runs, runs batted in, and home runs

Usage

rp(r, rbi, hr)

Arguments

r

Number of runs

rbi

Number of runs batted in

hr

Number of home runs

Value

rp

Examples

Run this code
# NOT RUN {
rp(70, 41, 22)
# }

Run the code above in your browser using DataLab