pgu.validator: pgu.validator

Description Format Details Active bindings Methods Author(s)

Description

Validates that the distribution is not significantly altered by the imputation process. This object is used by the shiny based gui and is not for use in individual R-scripts!

Format

R6::R6Class object.

Details

Takes two distributions (before and after imputation). Performs a Wilcoxon-Mann-Whitney U test. Performs a Kolmogorow-Smirnow test.

Active bindings

testStatistics_df

Returns the instance variable testStatistics_df. (tibble::tibble)

centralMoments_org

Returns the instance variable centralMoments_org (tibble::tibble)

centralMoments_imp

Returns the instance variable centralMoments_imp (tibble::tibble)

centralMoments_delta

Returns the instance variable centralMoments_delta (tibble::tibble)

features

Returns the instance variable features (character)

seed

Returns the instance variable seed (integer)

setSeed

Sets the instance variable seed. (numeric)

Methods

Public methods


Method new()

Creates and returns a new pgu.validator object.

Usage
pgu.validator$new(seed = 42)
Arguments
seed

Set the instance variable seed. (integer)

Returns

A new pgu.validator object. (pguIMP::pgu.validator)


Method finalize()

Clears the heap and indicates that instance of pgu.validator is removed from heap.

Usage
pgu.validator$finalize()

Method print()

Prints instance variables of a pgu.validator object.

Usage
pgu.validator$print()
Returns

string


Method resetValidator()

Resets instance variables

Usage
pgu.validator$resetValidator()

Method kolmogorowTestFeature()

Performs a comparison between the original and the imputated distribution of a given feature using a two-sided Kolmorogow-Smirnow test with simulated p-vaue distribution.

Usage
pgu.validator$kolmogorowTestFeature(
  org = "numeric",
  imp = "numeric",
  feature = "character"
)
Arguments
org

Original data to be analzed. (numeric)

imp

Imputed data to be analyzed. (numeric)

feature

Feature name of the analyzed distributions. (character)

Returns

One row dataframe comprising the test results. (tibble::tibble)


Method wilcoxonTestFeature()

Performs a comparison between the original and the imputated distribution of a given feature using a two-sided Wilcoxon/Mann-Whitney test.

Usage
pgu.validator$wilcoxonTestFeature(
  org = "numeric",
  imp = "numeric",
  feature = "character"
)
Arguments
org

Original data to be analzed. (numeric)

imp

Imputed data to be analyzed. (numeric)

feature

Feature name of the analyzed distributions. (character)

Returns

One row dataframe comprising the test results. (tibble::tibble)


Method centralMomentsFeature()

Estimates estimates the central moments of the given distribution.

Usage
pgu.validator$centralMomentsFeature(values = "numeric", feature = "character")
Arguments
values

Data to be analzed. (numeric)

feature

Feature name of the analyzed distributions. (character)

Returns

One row dataframe comprising the statistics. (tibble::tibble)


Method validate()

Validates the feature distributions of the original and the imputated dataframeā€œ using a two-sided Kolmorogow-Smirnow test and a two-sided Wilcoxon/Mann-Whitney test. The result is stored in the instance variables testStatistics_dfand 'distributionStatistics_df'. Displays the progress if shiny is loaded.

Usage
pgu.validator$validate(
  org_df = "tbl_df",
  imp_df = "tbl_df",
  progress = "Progress"
)
Arguments
org_df

Original dataframe to be analzed. (tibble::tibble)

imp_df

Imputed dataframe to be analyzed. (tibble::tibble)

progress

If shiny is loaded, the analysis' progress is stored in this instance of the shiny Progress class. (shiny::Progress)


Method featurePdf()

Receives a dataframe and plots the pareto density of the features 'org_pdf' and 'imp_pdf'. Returns the plot

Usage
pgu.validator$featurePdf(data_df = "tbl_df")
Arguments
data_df

dataframe to be plotted (tibble::tibble)

Returns

A ggplot2 object (ggplot2::ggplot)


Method featureCdf()

Receives a dataframe and plost the feature 'x' against the features 'org_cdf' and 'imp_cdf'. Returns the plot

Usage
pgu.validator$featureCdf(data_df = "tbl_df")
Arguments
data_df

dataframe to be plotted (tibble::tibble)

Returns

A ggplot2 object (ggplot2::ggplot)


Method featureVs()

Receives two numeric vectors 'org' and 'imp'. Plots the qq-plot of both vectors. Returns the plot

Usage
pgu.validator$featureVs(org = "numeric", imp = "numeric")
Arguments
org

Numric vector comprising the original data. (numeric)

imp

Numeric vector comprising the imputed data. (numeric)

Returns

A ggplot2 object (ggplot2::ggplot)


Method featureBoxPlot()

Receives a dataframe and information about the lloq and uloq and retuns a boxplot

Usage
pgu.validator$featureBoxPlot(
  data_df = "tbl_df",
  lloq = "numeric",
  uloq = "numeric",
  feature = "character"
)
Arguments
data_df

Dataframe to be analyzed (tibble::tibble)

lloq

lower limit of quantification (numeric)

uloq

upper limit of quantification (numeric)

feature

Feature name (character)

Returns

A ggplot2 object (ggplot2::ggplot)


Method featurePlot()

Receives two numeric dataframes 'org_df' and 'imp_df', and a feature name. Creates a compund plot of the validation results for the given feature.. Returns the plot

Usage
pgu.validator$featurePlot(
  org_df = "tbl_df",
  imp_df = "tbl_df",
  lloq = "numeric",
  uloq = "numeric",
  impIdx_df = "tbl_df",
  feature = "character"
)
Arguments
org_df

Dataframe comprising the original data. (tibble::tibble)

imp_df

Dataframe comprising the imputed data. (tibble::tibble)

lloq

lower limit of quantification (numeric)

uloq

upper limit of quantification (numeric)

impIdx_df

dataframe comprising information about imputation sites (tibble::tibble)

feature

Feature name. (character)

Returns

A ggplot2 object (ggplot2::ggplot)


Method clone()

The objects of this class are cloneable with this method.

Usage
pgu.validator$clone(deep = FALSE)
Arguments
deep

Whether to make a deep clone.

Author(s)

Sebastian Malkusch, malkusch@med.uni-frankfurt.de


pguIMP documentation built on Sept. 30, 2021, 5:08 p.m.