Replaces in a given numeric matrix NA values per row or per column.

1 | ```
replace.NA(x, replacement, byRow = TRUE)
``` |

`x` |
numeric input matrix |

`replacement` |
numeric vector containing the values which are used for NA replacement. If byRow = TRUE, this vector must contain as many values as matrix X has rows. Else, this vector must contain as many elements as matrix X has columns. |

`byRow` |
logical. If TRUE, then NA values in row n are replaced by the value at position n in the vector 'replacement'. Else, NA values are replaced according to their column position. |

The numeric input matrix with replaced NA values.

Patrick Warnat mailto:p.warnat@dkfz-heidelberg.de

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.