checkData: Do some basic checks on a given data matrix

View source: R/checkData.R

checkDataR Documentation

Do some basic checks on a given data matrix

Description

Check a given data matrix for consistency with the format required for further analysis. The data must be a numeric matrix and not contain:

  • Inf values

  • NaN values

  • Rows or columns that consist of NA only

Usage

checkData(data, verbose = FALSE)

Arguments

data

matrix – Data to check.

verbose

boolean – If TRUE, the function prints messages whenever an error in the data set is found.

Value

isValid

boolean – TRUE if no errors were found, FALSE otherwise. isValid contains a set of attributes, these are:

  • isNumeric - TRUE if data is numeric, false otherwise

  • isInfinite - TRUE if data contains 'Inf' values, false otherwise

  • isNaN - TRUE if data contains 'NaN' values, false otherwise

  • isMatrix - TRUE if the data is in matrix format, FALSE otherwise

  • naRows - TRUE if data contains rows in which all elements are 'NA', FALSE otherwise

  • naCols - TRUE if data contains columns in which all elements are 'NA', FALSE otherwise

Author(s)

Wolfram Stacklies


hredestig/pcaMethods documentation built on Sept. 30, 2023, 10:38 a.m.