fmm_to_vec: Convert Matrix Market File to Numeric Vector

View source: R/fastMatMR-package.R

fmm_to_vecR Documentation

Convert Matrix Market File to Numeric Vector

Description

This function reads a Matrix Market file and converts it to a numeric vector in R.

Usage

fmm_to_vec(filename)

Arguments

filename

The name of the input Matrix Market file to be read.

Value

A numeric vector containing the data read from the Matrix Market file.

Examples

# Create
sample_vec <- c(1, 2, 3)
temp_file_vec <- tempfile(fileext = ".mtx")
write_fmm(sample_vec, temp_file_vec)
# Read
vec <- fmm_to_vec(temp_file_vec)

fastMatMR documentation built on Nov. 4, 2023, 1:08 a.m.