Learn R Programming

forestSAS (version 1.0.1)

list_to_matrix: Converting list to matrix

Description

Converting the data with class list to the data with class matrix

Usage

list_to_matrix(x, item = NA)

Arguments

x

Data with class list

item

After converting list to matrix, using NA to pad out the blanks within matrix

Value

Data with class matrix

Examples

Run this code
# NOT RUN {
# Creating a list data "datalist", and covert "datalist" to a matrix data "datamat"
datalist<-list(dataA=1:5,dataB=1:10,dataC=1:15,dataD=1:20)
datamat<-list_to_matrix(datalist)
datamat
# }

Run the code above in your browser using DataLab