Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bradyajohnston/wellr
Utilities for Working With Plate Based Data
https://github.com/bradyajohnston/wellr
96-well-plate biochemistry r r-package
Last synced: 22 days ago
JSON representation
Utilities for Working With Plate Based Data
- Host: GitHub
- URL: https://github.com/bradyajohnston/wellr
- Owner: BradyAJohnston
- License: other
- Created: 2022-03-25T13:16:33.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-05-20T07:05:31.000Z (6 months ago)
- Last Synced: 2024-10-08T09:21:26.749Z (about 1 month ago)
- Topics: 96-well-plate, biochemistry, r, r-package
- Language: R
- Homepage: https://bradyajohnston.github.io/wellr
- Size: 1.4 MB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.Rmd
- License: LICENSE
Awesome Lists containing this project
README
---
output: github_document
---```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```# wellr
[![CRAN status](https://www.r-pkg.org/badges/version/wellr)](https://CRAN.R-project.org/package=wellr) [![R-CMD-check](https://github.com/bradyajohnston/wellr/workflows/R-CMD-check/badge.svg)](https://github.com/bradyajohnston/wellr/actions) [![Codecov test coverage](https://codecov.io/gh/bradyajohnston/wellr/branch/master/graph/badge.svg)](https://app.codecov.io/gh/bradyajohnston/wellr?branch=master)
[![R-CMD-check](https://github.com/BradyAJohnston/wellr/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/BradyAJohnston/wellr/actions/workflows/R-CMD-check.yaml)A set of _tidy_ utilities for working with plate based data. Wet-lab experiments are often carried out in microplates of varying sizes. `{wellr}` aims to provide a cleaner interface to working with data from plate readers that works well within the `{tidyverse}` [design principles](https://design.tidyverse.org/unifying.html).
## Installation
### From R-Universe:
This is the recommended way to install the package - as it requires no additional dependencies. It is currently not available on CRAN.
``` r
install.packages("wellr", repos = "bradyajohnston.r-universe.dev")
```### From GitHub
``` r
# install.packages("remotes")
remotes::install_github("bradyajohnston/wellr")
```## Basic Examples
```{r example}
library(wellr)well_format("G8")
well_to_col_num("G8")
well_to_row_num("G8")
well_to_index("H1")
well_to_index("H1", colwise = TRUE)
well_from_index(37)
well_from_index(37, colwise = TRUE)
well_join(3, 8)
well_join("E", 10)
```## Reading Biotek
Get the file paths of the demo files.
```{r}
file_data <- system.file("extdata",
"20220929_1steptimer20.csv",
package = "wellr"
)file_meta <- system.file("extdata",
"20220929_1steptimer20_metainfo.csv",
package = "wellr"
)
```Read in an example plate from a Biotek plate reader.
```{r}
plate <- plate_read_biotek(file_data)
plate
``````{r}
plate |>
plate_add_meta(file_meta)
```### Read Biotek Wavelength Data
If the biotek `.csv` file includes spectral readings from different wavelengths, these won't be included in the regular `plate_read_biotek()` function's output - as they don't have associated time information.
The `plate_read_biotek_wl()` function extracts these readings, and the resulting data frame includes a `id` column, specifying which wavelength reading they come from.
```{r}
file_including_wavelength <- system.file(
"extdata", "2024-02-29_vio_GFP_main.csv",
package = "wellr"
)plate_read_biotek(file_including_wavelength)
```
If reading in fluorescent data, there will sometimes be two wavelengths reported in the `.csv`. By default just the first wavelength will be used for the column names, but you can ensure that both wavelengths are included by useing `second_wl = TRUE`. The `gfp` column now includes the second wavelength that the fluorescence was measured at.
```{r}
plate_read_biotek(file_including_wavelength, second_wl = TRUE)
```When reading the spectral data from the file, the readings do not include time data.
The resulting data frame will however include a `id` column with `id = 1` being the first reading, `id = 2` being the second reading etc.
```{r}
plate_read_biotek_wl(file_including_wavelength)
```## Creating Dummy Plates
Create a data frame for plate-based data.
```{r}
well_plate(8, 12)
```## Helpful Plotting Functions
```{r}
set.seed(3)
plate <- well_plate(8, 12)[, "well"]
plate$value <- rnorm(96, sd = 10)well_plot(plate, well, value)
```