down_job
依靠
up_job
,或者
或者
file_out()
创建人
启动\u作业
应该在命令中提到
下岗
.
使用up\u job返回值的示例
library(drake)
plan <- drake_plan(
db_path = create_sql_db_from(file_in("some_input.csv")),
down_job = download_from_sql(db = db_path, file_in("my_code.sql"))
)
plan
#> # A tibble: 2 x 2
#> target command
#> <chr> <chr>
#> 1 db_path "create_sql_db_from(file_in(\"some_input.csv\"))"
#> 2 down_job "download_from_sql(db = db_path, file_in(\"my_code.sql\"))"
config <- drake_config(plan)
vis_drake_graph(config)
文件路径示例
library(drake)
plan <- drake_plan(
up_job = create_sql_db_from(file_in("some_input.csv"), file_out("db_path")),
down_job = download_from_sql(file_in("db_path"), file_in("my_code.sql"))
)
plan
#> # A tibble: 2 x 2
#> target command
#> <chr> <chr>
#> 1 up_job "create_sql_db_from(file_in(\"some_input.csv\"), file_out(\"db_â¦
#> 2 down_job "download_from_sql(file_in(\"db_path\"), file_in(\"my_code.sql\â¦
config <- drake_config(plan)
vis_drake_graph(config)
于2019-01-25由
reprex package
(第0.2.1版)