-
Notifications
You must be signed in to change notification settings - Fork 129
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Creating plan in Rmd file - knit()
same chunk names
#330
Comments
Sorry, I am having trouble understanding the problem. Is |
Ah, just re-read the title: I think |
Closing because I assume this problem is related to duplicate chunk names (chunk names need to be unique among all the reports). Please correct me if I am wrong, and I will reopen. |
You are right - that is causing the problem, but it is not obv=ious that it is like that. I would suggest to add an informative warning int the vignette which deals with knitting.
But this question goes along the lines of isolation: Wherever I run `make()`, the result should be the same. In other words: If I run `make()` at an R prompt, Commandline (via littler) , from an R script, or from RStudio, the results should be the same - that is the principle of reproducibility as I understand it.
For this to work, the approach to compiling the targets probably needs to be tweaked. The best and safest option probably would be to do the compilation in a new `R -- vanilla session`, but I don’t know if this would be feasible (and possible).
But at least in the case of knitting, the `make()` process should not fail.
Rainer
… On 19 Mar 2018, at 15:06, Will Landau ***@***.***> wrote:
Closing because I assume this problem is related to duplicate chunk names (chunk names need to be unique among all the reports). Please correct me if I am wrong, and I will reopen.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub <#330 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AAdvBBVDfmc0cS9uQvl8Nmtjs42Ohlgpks5tf7tLgaJpZM4SwGk3>.
--
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys. (Germany)
University of Zürich
Cell: +41 (0)78 630 66 57
email: [email protected]
Skype: RMkrug
PGP: 0x0F52F982
|
I do agree, but |
No - it can't. But shouldn't creating a target, be independent from where it is build? This leads to the question already partly raised: how dependent is the target from the environment it is called in? How do loaded packages affect the result? Can local variables change the result? > plan <- drake_plan(test = x + 1)
> make(plan)
target test
fail test
Error: Target `test`` failed. Call `diagnose(test)` for details. Error message:
object 'x' not found
> x <- 1
> make(plan)
target test
> should always result in the same result, i.e. the error message. I don't know if it is possible anymore without breaking backward compatibility, but I think The fact that local variables are accessible during |
We can think about a separate session for |
Sounds good. Thanks. |
I am creating a drake plan in an R notebook for documentation purposes. The planknits at the end a. Rmd file:
at the same time, I have a setup chunk in the Rmd which creates plan as well as in the file
TEST.Rmd
This results in the file not be parsed. I know this is an unusual use (creating the plan in an R notebook).The text was updated successfully, but these errors were encountered: