Learn R Programming

biostats (version 1.1.1)

missing_values: Descriptive and Visual Missing Value Assessment

Description

Provides descriptive statistics and visualizations of missing values in a dataframe.

Usage

missing_values(data, color = "#79E1BE", all = FALSE)

# S3 method for missing_values print(x, ...)

# S3 method for outliers print(x, ...)

Value

An object of class "missing_values" containing descriptive statistics and ggplot objects.

Arguments

data

Dataframe containing the variables to be analyzed.

color

Character string indicating the color for missing values. Default: "#79E1BE"

all

Logical parameter that shows all variables including those without missing values. Default: FALSE.

x

An object of class "outliers".

...

Further arguments passed to or from other methods.

Methods (by generic)

  • print(missing_values): Print method for objects of class "missing_values".

Functions

  • print(outliers): Print method for objects of class "outliers".

Examples

Run this code
# Clinical dataset with missing values
clinical_df <- clinical_data(dropout = 0.1, missing = 0.05)

# Missing value analysis of only variables with missing values
missing_values(clinical_df)

# Show all variables including those without missing values
missing_values(clinical_df, all = TRUE)

Run the code above in your browser using DataLab