Learn R Programming

ciftiTools (version 0.18.0)

replace_NA_with_label: Replace NA values in dlabel "xifti" with a new label.

Description

NaN values will be converted to NA and also replaced.

Usage

replace_NA_with_label(
  xifti,
  NA_value = NULL,
  NA_label = "NA",
  NA_color = "#FFFFFFFF",
  idx = NULL
)

Value

xifti with a new label value for NA values

Arguments

xifti

The "xifti"

NA_value

The new label value for NA values. If NULL (default), use -1 if all existing label values are non-negative, otherwise use one less than the minimum existing label value.

NA_label

The new label name for NA values. Default: "NA".

NA_color

The new label color for NA values, as a hex code with alpha. Default: "#FFFFFFFF".

idx

Numeric vector indicating the "xifti" columns to add NA labels for. Default: NULL (add to all columns).