Skip to content
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

Paste the outputs of deparse() to guarantee a length-1 vector (Fixes #459) #461

Merged
merged 2 commits into from
Nov 3, 2023

Conversation

mikemahoney218
Copy link
Member

This PR fixes #459 by ensuring deparse() generates a length-1 vector. The code to build using_bootstraps is taken from deparse1(), which was added in R 4.0; once rsample drops support for 3.6 it might make sense to change this to deparse1() instead for readability. The new test is taken directly from #459 's excellent reprex.

deparse1() was added in 4.0.0, so copied the internals for back-compatibility.
@hfrick
Copy link
Member

hfrick commented Nov 3, 2023

Excellent, thank you very much! 🙌

@hfrick hfrick merged commit f476210 into main Nov 3, 2023
12 checks passed
@hfrick hfrick deleted the paste_deparse branch November 3, 2023 10:20
Copy link

This pull request has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex: https://reprex.tidyverse.org) and link to this issue.

@github-actions github-actions bot locked and limited conversation to collaborators Nov 18, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Odd error when combining nested_cv and sliding_period
2 participants