Learn R Programming

JointAI (version 1.1.0)

get_nranef: Extract the number of random effects

Description

This function extracts the number of random effects per variable and grouping level from the provided random effects formulas.

Usage

get_nranef(random, data)

Value

a list of named vectors of the numbers of random effects per variable, were each list element refers to a (hierarchical) grouping level.

Arguments

random

a random effect formula or list of random effects formulas

data

a data.frame