Skip to content

Commit

Permalink
write only first region out in model meta for API; suspend flow name …
Browse files Browse the repository at this point in the history
…check before writing due to #244
  • Loading branch information
WesIngwersen committed Dec 5, 2023
1 parent 9269c08 commit e47169d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions R/WriteModel.R
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ writeModelMetadata <- function(model, dirs) {
model_desc <- file.path(dirs$data, "models.csv")
ID <- model$specs$Model
Name <- model$specs$Model
Location <- model$specs$ModelRegionAcronyms
Location <- model$specs$ModelRegionAcronyms[1]
Description <- ""
#Add in sector schema for model
if (is.null(model$specs$DisaggregationSpecs)) {
Expand Down Expand Up @@ -276,8 +276,8 @@ writeModelMetadata <- function(model, dirs) {
flows <- flows[order(flows$ID),]
flows$Index <- c(1:nrow(flows)-1)
flows <- flows[, fields$flows]
checkNamesandOrdering(flows$ID, rownames(model$B),
"flows in flows.csv and rows in B matrix")
#checkNamesandOrdering(flows$ID, rownames(model$B),
# "flows in flows.csv and rows in B matrix")
utils::write.csv(flows, paste0(dirs$model, "/flows.csv"), na = "",
row.names = FALSE, fileEncoding = "UTF-8")

Expand Down

0 comments on commit e47169d

Please sign in to comment.