From 9c9179fd0176d8ec263fc8108aff24d7e295592d Mon Sep 17 00:00:00 2001 From: matthias-da Date: Mon, 4 Dec 2023 17:15:04 +0100 Subject: [PATCH] =?UTF-8?q?=E2=80=9C=C2=80=C2=9D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- R/GUIfunctions.R | 10 +++++----- R/LocalRecProg.R | 2 +- R/aux_functions.r | 2 +- R/dRisk.R | 2 +- R/dataGen.r | 2 +- R/globalRecode.R | 2 +- R/indivRisk.R | 2 +- R/localSuppression.R | 2 +- R/measure_risk.R | 4 ++-- R/microaggregation.R | 2 +- R/rankSwap.R | 4 ++-- man/LocalRecProg.Rd | 2 +- man/dRisk.Rd | 2 +- man/dataGen.Rd | 2 +- man/extractManipData.Rd | 2 +- man/globalRecode.Rd | 2 +- man/indivRisk.Rd | 2 +- man/localSuppression.Rd | 2 +- man/measure_risk.Rd | 4 ++-- man/microaggregation.Rd | 2 +- man/rankSwap.Rd | 4 ++-- man/subsetMicrodata.Rd | 10 +++++----- 22 files changed, 34 insertions(+), 34 deletions(-) diff --git a/R/GUIfunctions.R b/R/GUIfunctions.R index 0e94b5de..6bf6978d 100644 --- a/R/GUIfunctions.R +++ b/R/GUIfunctions.R @@ -569,11 +569,11 @@ importProblem <- function(path) { #' #' @param obj an object of class \code{\link{data.frame}} containing micro data #' @param type algorithm used to sample from original microdata. Currently supported choices are -#' \itemize{ -#' \item \code{n_perc}{ the restricted microdata will be a \code{n-percent} sample of the original microdata.} -#' \item \code{first_n}{ only the first \code{n} observations will be used.} -#' \item \code{every_n}{ the restricted microdata set consists of every \code{n-th} record.} -#' \item \code{size_n}{ a total of \code{n} observations will be randomly drawn.} +#' \describe{ +#' \item{\code{n_perc}}{ the restricted microdata will be a \code{n-percent} sample of the original microdata.} +#' \item{\code{first_n}}{ only the first \code{n} observations will be used.} +#' \item{\code{every_n}}{ the restricted microdata set consists of every \code{n-th} record.} +#' \item{\code{size_n}}{ a total of \code{n} observations will be randomly drawn.} #' } #' @param n numeric vector of length 1 specifying the specific parameter with respect to argument \code{type}. #' @return an object of class \code{\link{sdcMicroObj-class}} with modified slot \code{@origData}. diff --git a/R/LocalRecProg.R b/R/LocalRecProg.R index dec85804..612775b8 100644 --- a/R/LocalRecProg.R +++ b/R/LocalRecProg.R @@ -20,7 +20,7 @@ #' @param lowMemory Slower algorithm with less memory consumption #' @param missingValue The output value for a suppressed value. #' @param ... see arguments below -#' \itemize{ +#' \describe{ #' \item{categorical}{Names of categorical variables} #' \item{numerical}{Names of numerical variables}} #' @return dataframe with original variables and the supressed variables diff --git a/R/aux_functions.r b/R/aux_functions.r index 31501aa2..2d6d33a9 100644 --- a/R/aux_functions.r +++ b/R/aux_functions.r @@ -410,7 +410,7 @@ setMethod(f="calcRisksX", signature=c("sdcMicroObj"), definition=function(obj, . #' the unchanged original variables #' @param randomizeRecords (logical) specifies, if the output records should be randomized. The following #' options are possible: -#' \itemize{ +#' \describe{ #' \item {'no'}{default, no randomization takes place} #' \item {'simple'}{records are just randomly swapped.} #' \item {'byHH'}{if slot 'hhId' is not \code{NULL}, the clusters defined by this variable are randomized across the dataset. If diff --git a/R/dRisk.R b/R/dRisk.R index 4a4336e8..f75ca59e 100644 --- a/R/dRisk.R +++ b/R/dRisk.R @@ -11,7 +11,7 @@ #' @name dRisk #' @param obj a \code{data.frame} or object of class \code{\link{sdcMicroObj-class}} #' @param ... possible arguments are: -#' \itemize{ +#' \describe{ #' \item {\code{xm}: }{perturbed data} #' \item {\code{k}: }{percentage of the standard deviation}} #' @return The disclosure risk or/and the modified \code{\link{sdcMicroObj-class}} diff --git a/R/dataGen.r b/R/dataGen.r index 9183ebb9..84e3c476 100644 --- a/R/dataGen.r +++ b/R/dataGen.r @@ -9,7 +9,7 @@ #' @docType methods #' @param obj an \code{\link{sdcMicroObj-class}}-object or a \code{data.frame} #' @param ... see possible arguments below -#' \itemize{ +#' \describe{ #' \item{n:}{ amount of observations for the generated data, defaults to 200} #' \item{use:}{ howto compute covariances in case of missing values, see also argument \code{use} in \code{\link{cov}}. #' The default choice is 'everything', other possible choices are 'all.obs', 'complete.obs', 'na.or.complete' or 'pairwise.complete.obs'.}} diff --git a/R/globalRecode.R b/R/globalRecode.R index 6a83c670..38ca862d 100644 --- a/R/globalRecode.R +++ b/R/globalRecode.R @@ -10,7 +10,7 @@ #' @param obj a numeric vector, a \code{data.frame} or an object of class #' \code{\link{sdcMicroObj-class}} #' @param ... see possible arguments below -#' \itemize{ +#' \describe{ #' \item{column: }{which keyVar should be changed. Character vector of length 1 specifying the variable name that #' should be recoded (required if \code{obj} is a \code{data.frame} or #' an object of class \code{\link{sdcMicroObj-class}}.} diff --git a/R/indivRisk.R b/R/indivRisk.R index 7709e0ba..9565bb4d 100644 --- a/R/indivRisk.R +++ b/R/indivRisk.R @@ -12,7 +12,7 @@ #' @param qual final correction factor #' @param survey TRUE, if we have survey data and FALSE if we deal with a population. #' @return -#' \itemize{ +#' \describe{ #' \item{rk: }{ base individual risk } #' \item{method: }{method} #' \item{qual: }{final correction factor} diff --git a/R/localSuppression.R b/R/localSuppression.R index 41c43c92..0e8ee5d2 100644 --- a/R/localSuppression.R +++ b/R/localSuppression.R @@ -30,7 +30,7 @@ #' subsets by specifying k as a vector. If k has only one element, the same value #' of k will be used for all subgroups. #' @param ... see arguments below -#' \itemize{ +#' \describe{ #' \item{keyVars: }{names (or indices) of categorical key variables (for data-frame method)} #' \item{strataVars: }{name (or index) of variable which is used for stratification purposes, used #' in the data.frame method. This means that k-anonymity is provided within each category diff --git a/R/measure_risk.R b/R/measure_risk.R index 79f98616..1e9c9c12 100644 --- a/R/measure_risk.R +++ b/R/measure_risk.R @@ -45,7 +45,7 @@ #' @param obj Object of class \code{\link{sdcMicroObj-class}} #' @param x Output of measure_risk() or ldiversity() #' @param ... see arguments below -#' \itemize{ +#' \describe{ #' \item{data: }{Input data, a data.frame.} #' \item{keyVars: }{names (or indices) of categorical key variables (for data-frame method)} #' \item{w: }{name of variable containing sample weights} @@ -54,7 +54,7 @@ #' \item{fast_hier: }{If TRUE a fast approximation is computed if household data are provided.} #' } #' @return A modified \code{\link{sdcMicroObj-class}} object or a list with the following elements: -#' \itemize{ +#' \describe{ #' \item{global_risk_ER: }{expected number of re-identification.} #' \item{global_risk: }{global risk (sum of indivdual risks).} #' \item{global_risk_pct: }{global risk in percent.} diff --git a/R/microaggregation.R b/R/microaggregation.R index e4299726..73ce25f1 100644 --- a/R/microaggregation.R +++ b/R/microaggregation.R @@ -74,7 +74,7 @@ #' @return If \sQuote{obj} was of class \code{\link{sdcMicroObj-class}} the corresponding #' slots are filled, like manipNumVars, risk and utility. If \sQuote{obj} was #' of class \dQuote{data.frame}, an object of class \dQuote{micro} with following entities is returned: -#' \itemize{ +#' \describe{ #' \item{\code{x}: }{original data} #' \item{\code{mx}: }{the microaggregated dataset} #' \item{\code{method}: }{method} diff --git a/R/rankSwap.R b/R/rankSwap.R index c0faee04..bbf1df76 100644 --- a/R/rankSwap.R +++ b/R/rankSwap.R @@ -7,10 +7,10 @@ #' #' Rank swapping sorts the values of one numeric variable by their numerical #' values (ranking). The restricted range is determined by the rank of two -#' swapped values, which cannot differ, by definition, by more than \eqn{P}{P} +#' swapped values, which cannot differ, by definition, by more than P #' percent of the total number of observations. Only positive P, R0 and K0 are #' used and only one of it must be supplied. If none is supplied, sdcMicro sets -#' parameter eqn{R0} to 0.95 internally. +#' parameter r0 to 0.95 internally. #' #' @name rankSwap #' @docType methods diff --git a/man/LocalRecProg.Rd b/man/LocalRecProg.Rd index 83ec4955..fa6e2f5f 100644 --- a/man/LocalRecProg.Rd +++ b/man/LocalRecProg.Rd @@ -36,7 +36,7 @@ results in complete matches of the data.} \item{missingValue}{The output value for a suppressed value.} \item{...}{see arguments below -\itemize{ +\describe{ \item{categorical}{Names of categorical variables} \item{numerical}{Names of numerical variables}}} } diff --git a/man/dRisk.Rd b/man/dRisk.Rd index 3eb4ab89..91ee9aa8 100644 --- a/man/dRisk.Rd +++ b/man/dRisk.Rd @@ -10,7 +10,7 @@ dRisk(obj, ...) \item{obj}{a \code{data.frame} or object of class \code{\link{sdcMicroObj-class}}} \item{...}{possible arguments are: -\itemize{ +\describe{ \item {\code{xm}: }{perturbed data} \item {\code{k}: }{percentage of the standard deviation}}} } diff --git a/man/dataGen.Rd b/man/dataGen.Rd index 216c08ae..209cb8f5 100644 --- a/man/dataGen.Rd +++ b/man/dataGen.Rd @@ -11,7 +11,7 @@ dataGen(obj, ...) \item{obj}{an \code{\link{sdcMicroObj-class}}-object or a \code{data.frame}} \item{...}{see possible arguments below -\itemize{ +\describe{ \item{n:}{ amount of observations for the generated data, defaults to 200} \item{use:}{ howto compute covariances in case of missing values, see also argument \code{use} in \code{\link{cov}}. The default choice is 'everything', other possible choices are 'all.obs', 'complete.obs', 'na.or.complete' or 'pairwise.complete.obs'.}}} diff --git a/man/extractManipData.Rd b/man/extractManipData.Rd index 65dac0f9..59a3d550 100644 --- a/man/extractManipData.Rd +++ b/man/extractManipData.Rd @@ -34,7 +34,7 @@ the unchanged original variables} \item{randomizeRecords}{(logical) specifies, if the output records should be randomized. The following options are possible: -\itemize{ +\describe{ \item {'no'}{default, no randomization takes place} \item {'simple'}{records are just randomly swapped.} \item {'byHH'}{if slot 'hhId' is not \code{NULL}, the clusters defined by this variable are randomized across the dataset. If diff --git a/man/globalRecode.Rd b/man/globalRecode.Rd index 7c84a28d..2d21ef16 100644 --- a/man/globalRecode.Rd +++ b/man/globalRecode.Rd @@ -12,7 +12,7 @@ globalRecode(obj, ...) \code{\link{sdcMicroObj-class}}} \item{...}{see possible arguments below -\itemize{ +\describe{ \item{column: }{which keyVar should be changed. Character vector of length 1 specifying the variable name that should be recoded (required if \code{obj} is a \code{data.frame} or an object of class \code{\link{sdcMicroObj-class}}.} diff --git a/man/indivRisk.Rd b/man/indivRisk.Rd index b8ba096e..f3e451ac 100644 --- a/man/indivRisk.Rd +++ b/man/indivRisk.Rd @@ -16,7 +16,7 @@ indivRisk(x, method = "approx", qual = 1, survey = TRUE) \item{survey}{TRUE, if we have survey data and FALSE if we deal with a population.} } \value{ -\itemize{ +\describe{ \item{rk: }{ base individual risk } \item{method: }{method} \item{qual: }{final correction factor} diff --git a/man/localSuppression.Rd b/man/localSuppression.Rd index 8d3c9603..e5f6489d 100644 --- a/man/localSuppression.Rd +++ b/man/localSuppression.Rd @@ -29,7 +29,7 @@ subsets by specifying k as a vector. If k has only one element, the same value of k will be used for all subgroups.} \item{...}{see arguments below -\itemize{ +\describe{ \item{keyVars: }{names (or indices) of categorical key variables (for data-frame method)} \item{strataVars: }{name (or index) of variable which is used for stratification purposes, used in the data.frame method. This means that k-anonymity is provided within each category diff --git a/man/measure_risk.Rd b/man/measure_risk.Rd index e3a6aa17..70ca0cfc 100644 --- a/man/measure_risk.Rd +++ b/man/measure_risk.Rd @@ -19,7 +19,7 @@ ldiversity(obj, ldiv_index = NULL, l_recurs_c = 2, missing = -999, ...) \item{obj}{Object of class \code{\link{sdcMicroObj-class}}} \item{...}{see arguments below -\itemize{ +\describe{ \item{data: }{Input data, a data.frame.} \item{keyVars: }{names (or indices) of categorical key variables (for data-frame method)} \item{w: }{name of variable containing sample weights} @@ -38,7 +38,7 @@ ldiversity(obj, ldiv_index = NULL, l_recurs_c = 2, missing = -999, ...) } \value{ A modified \code{\link{sdcMicroObj-class}} object or a list with the following elements: -\itemize{ +\describe{ \item{global_risk_ER: }{expected number of re-identification.} \item{global_risk: }{global risk (sum of indivdual risks).} \item{global_risk_pct: }{global risk in percent.} diff --git a/man/microaggregation.Rd b/man/microaggregation.Rd index 34a56699..b0f59fe6 100644 --- a/man/microaggregation.Rd +++ b/man/microaggregation.Rd @@ -58,7 +58,7 @@ median or weighted mean.} If \sQuote{obj} was of class \code{\link{sdcMicroObj-class}} the corresponding slots are filled, like manipNumVars, risk and utility. If \sQuote{obj} was of class \dQuote{data.frame}, an object of class \dQuote{micro} with following entities is returned: -\itemize{ +\describe{ \item{\code{x}: }{original data} \item{\code{mx}: }{the microaggregated dataset} \item{\code{method}: }{method} diff --git a/man/rankSwap.Rd b/man/rankSwap.Rd index d028520d..e46fa632 100644 --- a/man/rankSwap.Rd +++ b/man/rankSwap.Rd @@ -69,10 +69,10 @@ determined and the correlation coefficient makes sense. \details{ Rank swapping sorts the values of one numeric variable by their numerical values (ranking). The restricted range is determined by the rank of two -swapped values, which cannot differ, by definition, by more than \eqn{P}{P} +swapped values, which cannot differ, by definition, by more than P percent of the total number of observations. Only positive P, R0 and K0 are used and only one of it must be supplied. If none is supplied, sdcMicro sets -parameter eqn{R0} to 0.95 internally. +parameter r0 to 0.95 internally. } \examples{ data(testdata2) diff --git a/man/subsetMicrodata.Rd b/man/subsetMicrodata.Rd index 4c7b608f..46c9d5b3 100644 --- a/man/subsetMicrodata.Rd +++ b/man/subsetMicrodata.Rd @@ -10,11 +10,11 @@ subsetMicrodata(obj, type, n) \item{obj}{an object of class \code{\link{data.frame}} containing micro data} \item{type}{algorithm used to sample from original microdata. Currently supported choices are -\itemize{ -\item \code{n_perc}{ the restricted microdata will be a \code{n-percent} sample of the original microdata.} -\item \code{first_n}{ only the first \code{n} observations will be used.} -\item \code{every_n}{ the restricted microdata set consists of every \code{n-th} record.} -\item \code{size_n}{ a total of \code{n} observations will be randomly drawn.} +\describe{ +\item{\code{n_perc}}{ the restricted microdata will be a \code{n-percent} sample of the original microdata.} +\item{\code{first_n}}{ only the first \code{n} observations will be used.} +\item{\code{every_n}}{ the restricted microdata set consists of every \code{n-th} record.} +\item{\code{size_n}}{ a total of \code{n} observations will be randomly drawn.} }} \item{n}{numeric vector of length 1 specifying the specific parameter with respect to argument \code{type}.}