pmpp_data: Transform a single variable in the matrix format into the long panel format
Description
This function transforms a matrix of data with cross-sectional
and time dimensions in rows and columns or columns and rows into
a panel-structured, 3-column data frame
Usage
pmpp_data(indata, t_dim = "cols", var_name = "Y")
Arguments
indata
matrix with a single variable
t_dim
character string, one of: 'cols', 'rows';
whether time dimension in indata is across columns or rows
var_name
character string; name of the variable in indata
Value
A data.frame with 3 columns: unit, time and variable's values.