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

Be sure that all the sample calls get the same random seed in syn_test_data #421

Closed
Melkiades opened this issue Mar 3, 2023 · 6 comments
Labels
chevron enhancement New feature or request good first issue Good for newcomers

Comments

@Melkiades
Copy link
Contributor

Melkiades commented Mar 3, 2023

there are three instances of sample in the syn_test_data that generate the data for testing for adlb (here

sample(x = c("LAST", "REPLICATED", "SINGLE"), size = n(), replace = TRUE, prob = c(0.3, 0.6, 0.1)),
and below.) Please set seed of find another way to generate data. Cheers

Originally posted by @BFalquet in #418 (comment)

This is generally to avoid further unwanted updates of testing snapshots. @clarkliming @BFalquet

@Melkiades Melkiades added enhancement New feature or request good first issue Good for newcomers chevron labels Mar 3, 2023
@edelarua
Copy link
Contributor

edelarua commented Mar 3, 2023

@Melkiades as discussed with Benoit, I will add the fix for this to #418.

@BFalquet
Copy link
Contributor

BFalquet commented Mar 3, 2023

btw, doesn't need to be the same seed everywhere, just need to be constant (i.e. explicitly declared)

@clarkliming
Copy link
Contributor

isn't this sufficient ?

set.seed(321)

@BFalquet
Copy link
Contributor

BFalquet commented Mar 3, 2023

apparently not (that was also a surprise for me). See: https://github.com/insightsengineering/chevron/pull/418/files#r1124228431

@BFalquet
Copy link
Contributor

BFalquet commented Mar 3, 2023

We should store syn_data as a fixed dataset, that would avoid all of this issue

@edelarua
Copy link
Contributor

edelarua commented Mar 3, 2023

Closed by 3e239d1

@edelarua edelarua closed this as completed Mar 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chevron enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

4 participants