check_step: Ensure the plate's status is at the right step

View source: R/plate-attribs.R

check_stepR Documentation

Ensure the plate's status is at the right step

Description

Before beginning a step, you can check to make sure the plate is currently at most one step behind the current step. If the plate is more than one step behind, an error will be thrown, so that the user will know they need to run the previous steps.

Usage

check_step(plate, step)

Examples

## Not run: 
dir <- sample_data_dir()
plate <- new_plate(dir)
status(plate) # current step
check_step(plate, 2) # are we ready to start step 2?
check_step(plate, 3) # are we ready to start step 3?
plate <- next_step(plate)
status(plate)
check_step(plate, 3) # now are we ready to start step 3?

## End(Not run)

ddpcr documentation built on Aug. 21, 2023, 1:07 a.m.