This method allows for updating an existing complr object.
Usage
# S3 method for class 'complr'
update(object, newdata, ...)Value
A complr object with at least the following elements.
- X
- A vector of class - acomprepresenting one closed composition or a matrix of class- acomprepresenting multiple closed compositions each in one row.
- bX
- A vector of class - acomprepresenting one closed between-person composition or a matrix of class- acomprepresenting multiple closed between-person compositions each in one row.
- wX
- A vector of class - acomprepresenting one closed within-person composition or a matrix of class- acomprepresenting multiple closed within-person compositions each in one row.
- Z
- Log ratio transform of composition. 
- bZ
- Log ratio transform of between-person composition. 
- wZ
- Log ratio transform of within-person composition. 
- data
- The user's dataset or imputed dataset if the iiut data contains zeros. 
- transform
- Type of transform applied on compositional data. 
- parts
- Names of compositional variables. 
- idvar
- Name of the variable containing IDs. 
- total
- Total amount to which the compositions is closed. 
Examples
x <- complr(data = mcompd, sbp = sbp, 
               parts = c("TST", "WAKE", "MVPA", "LPA", "SB"), idvar = "ID")
# update with new data
newdat <- mcompd[ID != 1] # excluding ID 1
cilr1 <- update(object = x, newdata = newdat)
#> Error in complr(data = newdata, parts = parts, sbp = sbp, total = total,     idvar = idvar, transform = transform): parts should be a character vector or a list of character vectors.