Learn R Programming

mldr.datasets (version 0.4.2)

sparsity: Calculate the sparsity level of the dataset

Description

This function calculates the ratio of zero-valued elements over the total of elements. It is useful to decide whether to export in a dense or sparse format.

Usage

sparsity(mld)

Arguments

mld

An "mldr" object

Examples

Run this code
# NOT RUN {
library(mldr.datasets)
sparsity(emotions)
# }

Run the code above in your browser using DataLab