pred_curve: Predict Aging Curve

Description Usage Arguments Value

View source: R/age-curves.R

Description

Predicts the aging curve for a sequence of ages using the fixed effect coefficients from a fitted model

Usage

1
pred_curve(ages, coefs, poly_model)

Arguments

ages

numeric. The ages for which to estimate the player's aging curve.

coefs

The coefficients from the fitted model. Can be either a vector or a matrix where each column consists of a different set of coefficients.

poly_model

the model used to decompose the ages vector into orthogonal polynomials. Must have degree equal to the number of rows in the coefs matrix or, if coefs is a vector, the length of coefs.

Value

data.frame containing the ages and the estimated aging curve for each age.


guytuori/simScores documentation built on May 17, 2019, 9:29 a.m.