Learn R Programming

PvSTATEM - an R package for automated analysis of serological data

Overview

This package is a simple tool that handles various raw data formats produced in Multiplex Bead Assay (MBA). In short, it reads the unstructured, raw data from, e.g., the Luminex device and outputs normalised and well-structured data, which can be used later in more advanced downstream analysis.

The package includes three main steps for preprocessing the data:

  1. data reading and manipulation
  2. quality control
  3. data normalisation

The graphical overview of the package can be seen in the image below:

PvSTATEM package is developed within the project of the same name - PvSTATEM, an international project aiming at malaria elimination and is financially supported by the HORIZON grant HORIZON-WIDERA-2022-ACCESS-07-01.

Installation

The easiest way to install the package is using the CRAN repository:

install.packages("PvSTATEM")
require(PvSTATEM) # load the installed package

Now, you are ready to use the package to read your files!

Please note that since uploading the package to the CRAN repository requires the volunteers' time to manually run checks on the packages, the package version currently released on CRAN might not be the latest.

The package is under heavy development, with new features being released weekly. Therefore, if you'd like to test the latest package functionalities, we recommend installing it in the development version. It can be done using a simple command install_github available in the devtools library:

require(devtools)
install_github("mini-pw/PvSTATEM")
require(PvSTATEM) # load the installed package

The first command loads the devtools library (you might need to install it first - using the command install_packages("devtools")), and the second one sources the git repository with the code of our package and automatically installs it.

Examples and instructions

The example use of the package and its functionalities can be found in the vignettes. For more detailed documentation, check the package website.

Contributing and issues

As a project in the development phase, we are open to any suggestions, bug reports, and contributions. If you have any ideas or issues, please report them in the Issues section. Our team of developers will address them as soon as possible.

Copy Link

Version

Install

install.packages('PvSTATEM')

Monthly Downloads

274

Version

0.2.2

License

BSD_3_clause + file LICENSE

Issues

Pull Requests

Stars

Forks

Maintainer

Tymoteusz Kwiecinski

Last Published

February 27th, 2025

Functions in PvSTATEM (0.2.2)

format_dilutions

Format dilutions
get_location_matrix

Generate the matrix of plate locations
get_nmfi

Calculate normalised MFI values for a plate
generate_plate_report

Generate a report for a plate.
extract_dilution_from_names

Extract dilution factor from the sample name
extract_dilutions_from_layout

Extract dilutions from the layout representation
generate_levey_jennings_report

Generate a Levey-Jennings Report for Multiple Plates.
get_join_value

Determine the Join Value
extract_sample_names_from_layout

Extract sample names from layout
find_layout_file

Find a layout file given plate filepath
handle_high_dose_hook

Detect and handle the high dose hook effect
is_mba_format

Check if a mba format is supported
is_mba_data_file

Identify if a file is a MBA data file
handle_datetime

Handle differences in datetimes
is.decreasing

Check if the vector is monotically decreasing
is.str.number

Check if a string is a number
get_output_dir

Get output directory for a given input file
is.scalar

Check if a value is a scalar
is_outlier

Check if a value is an outlier
plot_counts

Plot counts in a 96-well plate
is_valid_sample_type

Check validity of given sample type
is_valid_data_type

Check validity of given data type
plot_standard_curve_analyte_with_model

Plot standard curve of a certain analyte with fitted model
plot_standard_curve_stacked

Standard curve stacked plot for levey-jennings report
merge_dataframes

Merge dataframes
plot_layout

Plot layout of a 96-well plate
plot_plate

Plot a 96-well plate with coloured wells
plot_standard_curve_analyte

Standard curves
plot_standard_curve_thumbnail

Standard curve thumbnail for report
process_plate

Process a plate and save output values to a CSV
process_dir

Process a dir of files to generate normalised data and reports
read_intelliflex_format

Read the Intelliflex format data
process_file

Process a file to generate normalised data and reports
predict.Model

Predict the RAU values from the MFI values
verbose_cat

Verbose Cat
verify_character_join

Verify Character Join
verify_numeric_join

Verify Numeric Join
plot_levey_jennings

Plot Levey-Jennings chart
plot_mfi_for_analyte

Plot MFI value distribution for a given analyte
read_layout_data

Read layout data from a file
translate_sample_names_to_sample_types

Translate sample names to sample types
read_luminex_data

Read Luminex Data
read_xponent_format

Read the xPONENT format data
remove_empty_lists

Remove Empty Lists from a List
validate_filepath_and_output_dir

Validate filepath and output_dir
sort_list_by

Sort a flat list by value
select_columns

Select Columns from a DataFrame
check_path_equal

Check if two paths are equal
create_vector_without_holes

Remove holes from a vector
create_standard_curve_model_analyte

Create a standard curve model for a certain analyte
Plate

Plate object
Model

Logistic regression model for the standard curve
PlateBuilder

PlateBuilder
dilution_to_rau

Convert dilution to RAU
clamp

Clamp a value to a range
detect_mba_format

Try to detect the format of a file
convert_dilutions_to_numeric

Convert dilutions to numeric values