assign_from_table {designit} | R Documentation |
Distributes samples based on a sample sheet.
Description
Distributes samples based on a sample sheet.
Usage
assign_from_table(batch_container, samples)
Arguments
batch_container |
Instance of BatchContainer class |
samples |
|
Value
Returns a new BatchContainer
.
Examples
bc <- BatchContainer$new(
dimensions = list(
plate = 2,
column = list(values = letters[1:3]),
row = 3
)
)
sample_sheet <- tibble::tribble(
~plate, ~column, ~row, ~sampleID, ~group,
1, "a", 1, 1, "TRT",
1, "b", 2, 2, "CNTRL",
2, "a", 1, 3, "TRT",
2, "b", 2, 4, "CNTRL",
2, "a", 3, 5, "TRT",
)
# assign samples from the sample sheet
bc <- assign_from_table(bc, sample_sheet)
bc$get_samples(remove_empty_locations = TRUE)
[Package designit version 0.5.0 Index]