Questions tagged [drake-r-package]

The drake R package is a Make-like pipeline toolkit. Its purpose is to enhance reproducibility, automation, speed, and scale in R-focused data science workflows. Use this tag for general questions about usage or for help optimizing and debugging drake-powered projects. For bug reports and feature requests, please post to the GitHub issue tracker.

Visit the following to learn more about the drake R package.

85 questions
0
votes
1 answer

How to map transform in r-drake

May i ask how to use function GraphLearner$new to transform in r-drake. The codes following: learner_plan = drake_plan( ## 1. Choose learner-------------------------------------------------------- polrn_classif =…
BinhNN
  • 87
  • 7
0
votes
0 answers

How to save 50% tuned results mlr3 and continue tune 50% tomorrow

Example codes library(mlr3verse) library(paradox) library(drake) my_plan = drake::drake_plan( # learner learner_classif = lrn( "classif.ranger", predict_type = "prob" ), # task task = tsk("german_credit"), # set…
BinhNN
  • 87
  • 7
0
votes
1 answer

Slurm + drake: free resources of idle job array workers for dynamic branching

EDIT: the question title and tags were adjusted after the discovery that the described behavior does not stem from SLURM but from the R package {drake} which is used as a proxy to execute SLURM array jobs. I've got the following situation: A Slurm…
pat-s
  • 5,992
  • 1
  • 32
  • 60
0
votes
0 answers

How to run parallel GRASS GIS mapsets from R using rgrass7 in a drake/targets pipeline?

I want to parallelize my GRASS GIS analysis and calculations using the package rgrass7 from within a targets pipeline. As I am a newbie to GRASS, I am not sure how to correctly set up multiple mapsets in the same GRASSGIS database. So far I tried…
MxNl
  • 371
  • 2
  • 9
0
votes
1 answer

Mapping one of three variables to target depending on earlier target parameter?

I am working on a Drake workflow that is defined as such: projectName <- c("lake_2018_CER_lib_norm_log2", "lake_2018_CER_lib_norm", "lake_2018_CER_raw_counts") normalize <- c(TRUE, TRUE, FALSE) logTransform <- c(TRUE, FALSE, FALSE) normalize_fxn <-…
0
votes
1 answer

Define default cache drake in global environment

i have a drake plan and intend to switch the cache directory based on the input data (i.e. input-dir1 -> results-dir1). This has the advantage, that I don't need to rerun the full pipeline, if the data source switches. Functions like make or loadd…
c0bra
  • 1,031
  • 5
  • 22
0
votes
1 answer

Drake is missing dependencies from a static branch only in some cases

I have a plan of a general form like the one below My real plan is more complex and I've been unable to reproduce this error in a toy example. Has anyone seen a problem like this and do you have any ideas about what might be causing it? The plan…
Richard J. Acton
  • 885
  • 4
  • 17
0
votes
0 answers

Optional dependencies in drake?

Consider the situation where I have some dependencies that are "optional" - sometimes I want to include them in my processing chain, sometimes I don't. e.g. the.plan <- drake_plan(A, B, C, …
Mark Payne
  • 557
  • 5
  • 12
0
votes
1 answer

How to combine and filter dynamic file targets in R drake?

I create a set of files in my drake plan. I want to copy a subset of these files to another location. The following code almost achieves that. However, drake's dependency tracking of file changes is lost after taking the subset of file targets that…
robust
  • 594
  • 5
  • 17
0
votes
1 answer

Workflow for drake plan with increasing input

I have a drake plan which uses a input folder with file_in. Then reads each file inside the folder and makes a number of transformations. Finally, it joins the results. If I add a new file, I would like that the new calculations in plan are only…
Javi_VM
  • 505
  • 2
  • 10
0
votes
1 answer

How do I read dynamic files in drake?

I want use drake's dynamic targets to read multiple files. I wrote the following plan based on my understanding of how dynamic files work. However, when the input file changes, drake does not correctly update all targets. What is the correct way to…
robust
  • 594
  • 5
  • 17
0
votes
0 answers

How do I integrate dynamic files into drake's cache?

I would like to use dynamic files for my drake plan. I have followed drake's documentation on dynamic files. However, drake does not seem to incorporate the file paths created into its cache. In the following reprex, plan_a follows the…
robust
  • 594
  • 5
  • 17
0
votes
1 answer

r drake file paths on windows messed up

I was trying to run a project with drake. The make(plan) runs through fine but after the the last point of the plan I receive an error. Error in file(private$total_file, "r+w") : cannot open connection Additional Warning: In file(private$total_file,…
marco
  • 80
  • 2
  • 7
0
votes
1 answer

Error when using initial_time_split with drake

Learning how to use drake with tidymodels. Something about using rsample's initial_time_split(), rather than just initial_split(), is giving me an error, when I run make(plan). I get the following: #> > target data #> > target split_data #> Error in…
0
votes
1 answer

How to deploy shiny app to shinyapps.io from drake plan

This is a follow-on question from closing the loop on passing the app and data to a Shiny deployment function: How to use shiny app as a target in drake I would like to deploy a Shiny app directly from a drake plan as…
David Lucey
  • 252
  • 3
  • 9