replace_values_float {mosbi} | R Documentation

## Replace values in a adjacency matrix.

### Description

Same as `replace_values`, but for (positive) non-integer matrices.

### Usage

    replace_values_float(mat, threshold, replace_higher = TRUE)

### Arguments

`mat` | A numeric matrix
`threshold` | All values in the matrix lower than this values are replaced by 0.
`replace_higher` | If set to true, all values >= `threshold` are replaced by 1.

### Details

Replace values in a numeric matrix, that are lower than a certain threshold.

### Value

A numeric matrix with (partially) replaced values.

### Examples

    replace_values(matrix(rnorm(100), nrow=10), threshold=1)

[Package mosbi version 1.0.3 Index]