fit_method.brokenstick: Get the result of fitting brokenstick to a dataset

Description Usage Arguments Details Note Examples

View source: R/analysis_fit_methods.R

Description

Get the result of fitting brokenstick to a dataset

Usage

1
2
## S3 method for class 'brokenstick'
fit_method(dat, ...)

Arguments

dat

data frame containing variables to model

...

additional parameters passed to brokenstick, most notably knots

Details

This essentially gets an anthropometric dataset into shape for brokenstick (sets appropriate data structure and removes missing values) and runs the fitting routine.

Note

The settings for x_trans and y_trans must match that used in fit_trajectory and appropriate inverse transformations must be set there accordingly as well.

Examples

1
2
3
4
5
6
## Not run: 
bsfit <- get_fit(cpp, y_var = "haz", method = "brokenstick")
fit <- fit_trajectory(subset(cpp, subjid == 2), fit = bsfit)
plot(fit)

## End(Not run)

hafen/hbgd documentation built on March 1, 2020, 5:31 p.m.