This function is the inverse of `matrix_to_triplets`

.
It converts a matrix represented as a set of triplets into
an object of the class `matrix`

. The missing entries
(the ones not present in the triplet representation) are
filled in as NA.

1 | ```
triplets_to_matrix(triplets)
``` |

`triplets` |
A matrix in triplet/coordinate format |

See `matrix_to_triplets`

for a description of the
representation.

The input matrix as a normal matrix of class `matrix`

Arto Klami and Lauri VĂ¤re

1 2 3 4 5 | ```
x <- matrix(c(1,2,NA,NA,5,6),nrow=3)
triplet <- matrix_to_triplets(x)
print(triplet)
xnew <- triplets_to_matrix(triplet)
print(xnew)
``` |

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.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.