Learn R Programming

mmrm (version 0.3.16)

h_check_fits_all_data_same: Predicate Indicating Whether mmrm Fits' Datasets Contain the Same Observations

Description

Checks a list of mmrm fits to see whether all their datasets contain the same observations and that they only increase in columns from one dataset to the next (i.e, columns are nested).

Usage

h_check_fits_all_data_same(fits)

Value

TRUE or FALSE indicating whether or not the datasets underlying the elements of fits contain the same observations, and that each dataset's columns are a subset of the next dataset's columns.

Arguments

fits

(list)
list of mmrm fits.

Details

For efficiency, the inspection takes place in this order:

  1. FALSE is returned early if not all datasets have the same number of rows.

  2. FALSE is returned early if a dataset has a column not in the next dataset.

  3. The columns in common among adjacent datasets are sorted and compared using all.equal() with check.attributes = FALSE.

This function is more efficient than running h_check_columns_nested() on all adjacent pairs and supplying the results to all().

See Also

h_check_columns_nested(), which performs this check on two data sets.