GroupedData object

Table-like collection of data and metadata

Description

The groupedData object is a table-like object that supports all the methods and properties of table and has two additional properties to identify the independent variable and an optional grouping variable. It also has additional methods that let you create doses from data set containing dosing data and convert a groupedData object to a table.

Constructor Summary

groupedDataCreate a groupedData object.

Method Summary

The groupedData object supports all methods of table and provides the following additional methods.

createDoses(groupedData)Create dose objects from groupedData object
groupedData2table (groupedData)Convert groupedData object to table

Properties

The groupedData object supports all properties of table and provides the following additional properties.

GroupVariableNameA string indicating the name of grouping variable that indicates the groups in the data. To indicate there are no groups (or just one group), set the property to the empty string ''.
IndependentVariableNameA string indicating the name of the independent variable in the data such as time. To indicate there is no independent variable, set the property to the empty string ''.

Examples

expand all

Create a GroupedData Object from Data Set

This example uses data collected on 59 preterm infants given phenobarbital during the first 16 days after birth. Each infant received an initial dose followed by one or more sustaining doses by intravenous bolus administration. A total of between 1 and 6 concentration measurements were obtained from each infant at times other than dose times, for a total of 155 measurements. Infant weights and APGAR scores (a measure of newborn health) were also recorded. Data is described in [1], a study funded by the NIH/NIBIB grant P41-EB01975.

Load the sample dataset.

load pheno.mat ds

Create a groupedData object from the data set ds.

grpData = groupedData(ds);

Display the properties.

grpData.Properties
ans = 

                Description: 'This dataset was generated using sbionmimport.

FileNa...'
       VariableDescriptions: {}
              VariableUnits: {}
             DimensionNames: {'Observations'  'Variables'}
                   UserData: []
                   RowNames: {}
              VariableNames: {'ID'  'Time'  'Dose'  'Response'}
          GroupVariableName: 'ID'
    IndependentVariableName: 'Time'

GroupVariableName and IndpendentVariableName have been automatically assigned to 'ID' and 'Time' respectively.

References

[1] Grasela Jr, T.H., Donn, S.M. (1985) Neonatal population pharmacokinetics of phenobarbital derived from routine clinical data. Dev Pharmacol Ther. 8(6), 374–83.

Was this topic helpful?