Create a model equation

create_equation(equation, indexes = NULL, type = c("defining", "mcc"),
  desc)

Arguments

equation

a string with the equation expression.

indexes

a vector with index and sets specifications. Example: "c in COM".

type

the equation type: "defining" or "mcc".

desc

equation description.

Value

A named list with the values and type for the variable.

Examples

create_equation( equation = "x[c] = alpha * M / p[c]", indexes = "c in COM", type = "defining", desc = "Commodity demand" )
#> $equation #> [1] "x[c] = alpha * M / p[c]" #> #> $indexes #> [1] "c in COM" #> #> $type #> [1] "defining" #> #> $desc #> [1] "Commodity demand" #>