Indices to new primary cells are returned
FixRiskyIntervals(
x,
z,
primary,
suppressed,
candidates = NULL,
minVal = NULL,
lpPackage = "lpSolve",
gaussI = FALSE,
allInt = FALSE,
sparseConstraints = TRUE,
rangeLimits,
cell_grouping = rep(0, length(z))
)
ModelMatrix, as output from SSBtools::ModelMatrix
numerical vector with length ncol(x). Corresponds to table cell values
Vector indicating primary suppressed cells. Can be logical or integer. If integer vector, indicates the columns of x which are considered primary suppressed.
Vector indicating all suppressed cells. Can be logical or integer. If integer vector, indicates the columns of x which are considered suppressed.
candidates
as indices
a known minimum value for table cells. Default NULL. Note that 'minVal' is interpreted as the limiting value for all suppressed cells. Specifying 'minVal=0' would be redundant, as a minimum value of 0 is anyway assumed for inner cells (see details).
The name of the package used to solve linear programs. Currently, 'lpSolve' (default), 'Rsymphony', 'Rglpk' and 'highs' are supported.
Boolean vector. If TRUE (default), GaussIndependent is used to reduce size of linear program.
Integer variables when TRUE.
See all.int
parameter in lpSolve
and types
parameter in Rsymphony
and Rglpk
.
When TRUE, a sparse constraint matrix will be input to the
solver. In the case of lpSolve
, the sparse matrix is represented in triplet form
as a dense matrix with three columns, and the dense.const
parameter is utilized.
As computed by RangeLimitsDefault
Numeric vector indicating group membership. Cells with the same value that is not 0 belong to the same group. A value of 0 indicates that the cell is not a member of any group. Members of the same group are assumed to have the same z-value and this is included as a condition when calculating intervals.
Code in this function started from a copy of ComputeIntervals