Title: | an R package for parsing UNcle data |
---|---|
Description: | UNcleR is an R package for parsing data exported from Unchained Labs UNcle instruments for the purpose of downstream analysis of biologics stability data. |
Authors: | Eric Hunt [aut, cre] |
Maintainer: | Eric Hunt <[email protected]> |
License: | MIT + file LICENSE |
Version: | 0.1 |
Built: | 2024-11-08 04:58:34 UTC |
Source: | https://github.com/eric-hunt/uncleR |
add_meta
add_meta(data, meta)
add_meta(data, meta)
data |
a dataframe to assign metadata to |
meta |
a named list of tibbles containing metadata for experiments imported from 'uncleR::get_meta' function defaults to c("well") |
a dataframe with metadata added as new variables, matched according to well
This function consolidates experiments for a protein based on directory hierarchy. The hierarchy should be as follows from within the working directory where these functions will be executed:
consolidate_experiments( prot_dir, join_vars = NULL, legacy = FALSE, SLSheader = TRUE, DLSheader = FALSE )
consolidate_experiments( prot_dir, join_vars = NULL, legacy = FALSE, SLSheader = TRUE, DLSheader = FALSE )
prot_dir |
a character string identical to subdirectory name of working directory where the experiment "Exports" folder is located for the protein being analyzed |
legacy |
a boolean value, TRUE if individual SLS/DLS spectra files were exported, FALSE if SLS/DLS "bundle" files were exported; default is FALSE |
SLSheader |
sets header argument for |
DLSheader |
sets header argument for |
<wd>/ <prot_dir>/ "Exports"/ "General Screen" "pH Screen" ...
The prot_dir
argument should match the name of the protein subdirectory within
the working directory. This is deliberate as it forces the user to make
a coherent choice about which data to process. Exported summary and spectra
should be contained within named subdirectories of a directory named "Exports"
located within the prot_dir
directory.
consolidate_experiments
a named list of dataframes containing the consolidated data for each experiment
get_meta
get_meta(path)
get_meta(path)
path |
a character string path to an Excel document containing metadata for each experiment in separate worksheets defaults to c("well") |
a named list of tibbles containing metadata for experiments
import_DLSspec
import_DLSspec( directory_path, pattern = NULL, type = NA, header = TRUE, combine = TRUE )
import_DLSspec( directory_path, pattern = NULL, type = NA, header = TRUE, combine = TRUE )
directory_path |
a path to a directory containing the exported .xlsx files |
pattern |
a regex pattern for further selecing files in the directory; defaults to NULL to force user input that discriminates intensity from mass DLS files |
type |
a character string, "C", "I", or "M", to signify if the data is correlation function, intensity, or mass distribution DLS spectra |
header |
if TRUE skips first 3 rows of .xlsx file to remove Uncle header; default is TRUE |
combine |
if TRUE, returns all imported data merged into one unified dataframe with an "origin" column listing the original file path, FALSE will return a list of dataframes; default is TRUE |
a named (with filename) list of dataframes or a single merged dataframe
import_DLSsum
import_DLSsum( directory_path, pattern = "DLS Sum", sheet = NULL, temp_cutoff = 25, header = FALSE, combine = TRUE )
import_DLSsum( directory_path, pattern = "DLS Sum", sheet = NULL, temp_cutoff = 25, header = FALSE, combine = TRUE )
directory_path |
a path to a directory containing the exported .xlsx files |
pattern |
a regex pattern for further selecing files in the directory, defaults to "DLS Sum" |
sheet |
character string to specify sheet if multi-sheet workbook is exported |
temp_cutoff |
numeric value, excluding all DLS data obtained at temperatures above this value, default is 100 (°C) |
header |
if TRUE skips first 4 rows of .xlsx file to remove Uncle header, default is FALSE |
combine |
if TRUE, returns all imported data merged into one unified dataframe with an "origin" column listing the original file path, FALSE will return a list of dataframes; default is TRUE |
a named (with filename) list of dataframes or a single merged dataframe
import_dynamicBundle
import_dynamicBundle( directory_path, pattern = "DLS Bundle", skip = 2, combine = TRUE )
import_dynamicBundle( directory_path, pattern = "DLS Bundle", skip = 2, combine = TRUE )
directory_path |
a path to a directory containing the exported .xlsx files |
pattern |
a regex for narrowing selection of files in the 'directory_path'; defaults to "DLS Bundle" |
skip |
number of rows of embedded run metadata in the .xlsx file to remove; default is 2 |
combine |
if TRUE, returns all imported data merged into one unified dataframe with an "origin" column listing the original file path, FALSE will return a list of dataframes; default is TRUE |
Note: This import function will only import DLS spectra performed at the beginning of the temperature ramp, i.e. the lowest temperature.
a named (with filename) list of dataframes or a single merged dataframe
import_FLUORspec
import_FLUORspec( directory_path, pattern = "Tm Spec", header = TRUE, combine = TRUE )
import_FLUORspec( directory_path, pattern = "Tm Spec", header = TRUE, combine = TRUE )
directory_path |
a path to a directory containing the exported .xlsx files |
pattern |
a regex pattern for further selecing files in the directory; defaults to "Tm Spec" |
header |
if TRUE skips first 3 rows of .xlsx file to remove Uncle header; default is TRUE |
combine |
if TRUE, returns all imported data merged into one unified dataframe with an "origin" column listing the original file path, FALSE will return a list of dataframes; default is TRUE |
a named (with filename) list of dataframes or a single merged dataframe
import_SLSspec
import_SLSspec( directory_path, pattern = "SLS Spec", lambda = 266, header = TRUE, combine = TRUE )
import_SLSspec( directory_path, pattern = "SLS Spec", lambda = 266, header = TRUE, combine = TRUE )
directory_path |
a path to a directory containing the exported .xlsx files |
pattern |
a regex pattern for further selecing files in the directory; defaults to SLS Spec |
lambda |
a number value representing wavelength for Tagg spectra, typically 266nm for small aggregates and 473nm for large aggregates; default is 266nm |
header |
if TRUE skips first 1 rows of .xlsx file to remove Uncle header; default is TRUE |
combine |
if TRUE, returns all imported data merged into one unified dataframe with an "origin" column listing the original file path, FALSE will return a list of dataframes; default is TRUE |
a named (with filename) list of dataframes or a single merged dataframe
import_SLSsum
import_SLSsum( directory_path, pattern = "SLS Sum", sheet = NULL, header = FALSE, combine = TRUE )
import_SLSsum( directory_path, pattern = "SLS Sum", sheet = NULL, header = FALSE, combine = TRUE )
directory_path |
a path to a directory containing the exported .xlsx files |
pattern |
a regex pattern for further selecing files in the directory; defaults to "SLS Sum" |
sheet |
character string to specify sheet if multi-sheet workbook is exported |
header |
if TRUE skips first 4 rows of .xlsx file to remove Uncle header; default is FALSE |
combine |
if TRUE, returns all imported data merged into one unified dataframe with an "origin" column listing the original file path, FALSE will return a list of dataframes; default is TRUE |
a named (with filename) list of dataframes or a single merged dataframe
import_staticBundle
import_staticBundle( directory_path, pattern = "SLS Bundle", skip = 3, combine = TRUE )
import_staticBundle( directory_path, pattern = "SLS Bundle", skip = 3, combine = TRUE )
directory_path |
a path to a directory containing the exported .xlsx files |
pattern |
a regex for narrowing selection of files in the 'directory_path'; defaults to "SLS Bundle" |
skip |
number of rows of embedded run metadata in the .xlsx file to remove; default is 3 |
combine |
if TRUE, returns all imported data merged into one unified dataframe with an "origin" column listing the original file path, FALSE will return a list of dataframes; default is TRUE |
a named (with filename) list of dataframes or a single merged dataframe
join_SLS_DLS
join_SLS_DLS(SLS_data, DLS_data, .by = c("well", "sample_num", "prot_conc"))
join_SLS_DLS(SLS_data, DLS_data, .by = c("well", "sample_num", "prot_conc"))
SLS_data |
a dataframe object containing SLS data |
DLS_data |
a dataframe object containing DLS data |
.by |
a character vector of variable names by which to join tables; defaults to c("well", "sample_num", "prot_conc") |
a dataframe