Skip to content

Commit

Permalink
replace - and unmute c#
Browse files Browse the repository at this point in the history
  • Loading branch information
marinakiweler committed Feb 11, 2019
1 parent 15c426c commit 419d104
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions R/load_meta_functions.R
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#' create a JSON File
#'
#' @param path_data Path to raw file or directory containing raw files.
#' @param silent Error and informational output is hidden if FALSE.
#'
#' @return JSON object containing the meta data of the raw files.
#'
Expand All @@ -20,7 +21,7 @@
#' }
#' @export

generate_json <- function(path_data)
generate_json <- function(path_data, silent = FALSE)
{
new_file <- tempfile()
path_MARMoSET_exe <- system.file(
Expand All @@ -34,14 +35,15 @@ generate_json <- function(path_data)
msg = "path_data is not a file or directory!",
severity = "stop",
what = "any")
assertive.types::assert_is_a_bool(silent)

if(!assertive.reflection::is_windows())
{
stop("Function is only working under windows.")
}

system(command = paste(path_MARMoSET_exe, paste0('"',path_data, '"'), new_file),
intern = T)
show.output.on.console = !silent)

json <- jsonlite::fromJSON(new_file)

Expand Down
Binary file added R/sysdata.rda
Binary file not shown.
2 changes: 1 addition & 1 deletion R/term_matching_functions.R
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ one_group_match_terms <- function(flat_json, term_matching_table, group_number)
}
}

meta_data_table %<>% dplyr::mutate(Value = Value %>% stringi::stri_replace_first_fixed('','-'))
meta_data_table %<>% dplyr::mutate(Value = Value %>% stringi::stri_replace_first_fixed('\U2015','-'))

return(meta_data_table)
}

0 comments on commit 419d104

Please sign in to comment.