Learn R Programming

iotables (version 0.9.4)

conforming_vector_create: Create an Empty Conforming Vector

Description

Create a named vector (in wide format) that conforms to the structure of a given analytical object, such as a use table, coefficient matrix, or Leontief matrix. This helps avoid mistakes when manually defining large vectors (e.g., for 60 × 60 matrices).

Usage

conforming_vector_create(data_table)

Value

A one-row data.frame with the same column names as data_table, but with all values set to zero.

Arguments

data_table

A use table, coefficient matrix, Leontief matrix, or other named matrix or data frame.

Details

The empty conforming vector can also be exported to .csv format and used as a template for importing scenarios from a spreadsheet application.

See Also

Other iotables processing functions: empty_remove(), household_column_find(), household_column_get(), iotable_year_get(), key_column_create(), matrix_round(), output_get(), primary_input_get(), rows_add(), supplementary_add(), total_tax_add(), vector_transpose_longer(), vector_transpose_wider()

Examples

Run this code
de_input_flow <- input_flow_get(data_table = iotable_get())
conforming_vector_create(de_input_flow)

Run the code above in your browser using DataLab