move using outside the function:
# example 1: minimal options/arguments, auto-generated help/version
using Distributed
using ArgParse
@everywhere using StatsBase
function main(args)
s = ArgParseSettings("Run deconvolution: " * # description
"flags, options help, " *
"required arguments.")
@add_arg_table! s begin
"--opt1"
help = "an option" # used by the help screen
"--opt2", "-o"
action = :store_true # this makes it a flag
help = "a flag"
"arg1"
help = "an argument"
required = true # makes the argument mandatory
end
parsed_args = parse_args(args, s)
println("Parsed args:")
for (key,val) in parsed_args
println(" $key => $(repr(val))")
end
addprocs(4)
end
main(ARGS)