Skip to content

Commit

Permalink
included k argument in to_wrf
Browse files Browse the repository at this point in the history
  • Loading branch information
Schuch666 committed Aug 23, 2024
1 parent c731187 commit c6ee9c5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions R/to_wrf.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
#' @param norm if the spatial weights need to be normalized (modifier)
#' @param profile temporal profile to expand the emissions (modifier)
#' @param weights weight of each species (modifier)
#' @param k constant passed to wrf_put
#' @param verbose display additional information
#'
#' @note length(profile) must be the number of times in the emission
Expand Down Expand Up @@ -76,6 +77,7 @@ to_wrf <- function(POL,
norm = FALSE,
profile = 1,
weights = 1,
k = 1,
verbose = TRUE){

if(is.matrix(POL)){
Expand Down Expand Up @@ -113,7 +115,7 @@ to_wrf <- function(POL,
}
}
if(verbose)
cat(paste("writing emissions:", name[i],"weight", weights[i],'on file',file,'\n'))
wrf_put(file,name = name[i],weights[i]*VAR)
cat(paste("writing emissions:", name[i],"weight", k * weights[i],'on file',file,'\n'))
wrf_put(file,name = name[i],weights[i]*VAR, k = k)
}
}

0 comments on commit c6ee9c5

Please sign in to comment.