-
Notifications
You must be signed in to change notification settings - Fork 1
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
spatial()
assigns multiple samples to the same plate position in the same batch
#45
Comments
Hi Anna, happy to hear from a happy user. Sorry to hear that |
Hi Lluis,
Thank you very much for the super fast reply.
Here is the code and the dataset.
Thanks!
Anna
Il giorno mar 5 dic 2023 alle ore 12:15 Lluís Revilla <
***@***.***> ha scritto:
… Hi Anna, happy to hear from a happy user.
Sorry to hear that spatial doesn't fully work. I think I tested to
prevent this from happening, but I will give it a look. Could you provide
the code where this happens? This way I will make sure it won't happen
again.
—
Reply to this email directly, view it on GitHub
<#45 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AYJGFB5GHRC32OUCVBNILB3YH363RAVCNFSM6AAAAABAHO4A5WVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNBQGU2DEOJXGQ>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Sorry, if you send the data via email, I don't see it in the github issue. But don't worry that I found a way to reproduce the issue: data(survey, package = "MASS")
set.seed(4568)
nas <- c(137, 70)
index <- replicates(survey[-nas, c("Sex", "Smoke", "Age")], size_subset = 50,
iterations = 25, controls = 15)
index2 <- spatial(index, survey[-nas, c("Sex", "Smoke", "Age")], iterations = 25)
uniquness <- vapply(index2, function(x){length(unique(x)) == length(x)},
FUN.VALUE = logical(1L))
expect_false(any(!uniquness))
i1 <- inspect(index, survey[-nas, c("Sex", "Smoke", "Age")])
i2 <- inspect(index2, i1, index_name = "spatial")
# This should be empty too
i2 |> group_by(batch) |> count(spatial) |> ungroup() |> arrange(batch) |> filter(n!= 1) |
Oh, sorry, I didn't realise it. |
Hi Anna, I fixed this locally, thanks for opening the issue. However, I found that there is a problem with |
Hi Lluis,
I'm assigning the position to my controls separately, hence this should be
enough for now.
Thank you a lot for your work!
…On Thu, Dec 7, 2023, 11:24 Lluís Revilla ***@***.***> wrote:
Hi Anna, I fixed this locally, thanks for opening the issue. However, I
found that there is a problem with batch_names which affects inspect too
when there are controls or repeated positions. Do you have controls in your
data? Or would this be enough for the moment?
—
Reply to this email directly, view it on GitHub
<#45 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AYJGFB6ZUHO7FPZHSAMHWQLYIGKMZAVCNFSM6AAAAABAHO4A5WVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNBVGA3TKOJTHE>
.
You are receiving this because you authored the thread.Message ID:
***@***.***>
|
Hi Lluis, |
I meant that it was only in my computer, not yet on github or CRAN. To install the package with the fix you will need to use If it is not fixed then I would need to know the code used and the experDesign version used. |
Nice plot! I assume you blocked/omitted the first column? Or you only provided with columns 2 to 8? I think I reverted that change, it slipped through. You will need to repeat the steps in #45 (comment). |
Sorry, it was a typo, I have age as numeric indeed. |
It is perfectly working now! Thank you a lot! |
Glad it works now! I hope it helps well designing your experiment! |
Hi Lluís, thank you for this amazing package. I'm using it for my project, but I encountered some issues when distributing the samples in the plate grid. I have some cases where
spatial()
assigns the same position in the same batch to two samples.Could you help me with that?
Thank you a lot!
Best,
Anna
The text was updated successfully, but these errors were encountered: