Type: Package
Title: Biosensor Development using Omics Data
Version: 0.2.0
Maintainer: Takahiko Koizumi <takahiko.koizumi@gmail.com>
Description: A method for the quantitative prediction using omics data. This package provides functions to construct the quantitative prediction model using omics data.
Depends: R (≥ 3.5.0)
License: GPL (≥ 3)
Language: en-US
Encoding: UTF-8
LazyData: true
RoxygenNote: 7.2.3
Suggests: knitr, rmarkdown, testthat (≥ 3.0.0)
URL: <https://github.com/takakoizumi/OmicSense>
VignetteBuilder: knitr
Config/testthat/edition: 3
Imports: ggplot2, kernlab
NeedsCompilation: no
Packaged: 2023-09-22 21:14:43 UTC; taka
Author: Takahiko Koizumi [aut, cre], Kenta Suzuki [ctb], Yasunori Ichihashi [ctb]
Repository: CRAN
Date/Publication: 2023-09-22 21:30:08 UTC

Transcriptomes of Pinus roots under a Temperature Gradient

Description

This dataset gives the TPM values of 200 selected genes obtained from 60 Pinus root samples (30 samples each for training and test data) under a temperature gradient, generated by RNA-seq.

Usage

Pinus

Details

A gene expression data matrix of 30 root samples of P. thunbergii under five temperature conditions (8, 13, 18, 23, 28 °C) with six biological replicates is in the first element of the list.

A gene expression data matrix of another 30 root samples of P. thunbergii under the same condition is in the second one.

Temperature conditions where 30 root samples in each data matrix were generated are in the third one.

Gene expressions are normalized in the TPM value.

Source

original (not published)

References

original (not published)


Clean data by eliminating predictors with many missing values

Description

Clean data by eliminating predictors with many missing values

Usage

os.clean(x, missing = 0.1, lowest = 10)

Arguments

x

A data matrix (raw: samples, col: predictors).

missing

A ratio of missing values in each column allowed to be remained in the data.

lowest

The lowest value to be leaved in the data.

Value

A data matrix (raw: samples, col: qualified predictors)

Author(s)

Takahiko Koizumi

Examples

data(Pinus)
train.raw <- Pinus$train
ncol(train.raw)

train <- os.clean(train.raw)
ncol(train)

Visualize predictors using principal coordinate analysis

Description

Visualize predictors using principal coordinate analysis

Usage

os.pca(x, y, method = "linear", thresh = 0, n.pred = ncol(x), size = 1)

Arguments

x

A data matrix (row: samples, col: predictors).

y

A vector of target value.

method

A string to specify the regression function for calculating R-squared values. "linear" (default), "quadratic" or "cubic" function can be specified.

thresh

The lower threshold of R-squared value to be indicated in a PCA plot (default: 0).

n.pred

The number of candidate predictors for prediction model to be indicated in a PCA plot (default: ncol(x)).

size

The size of symbols in a PCA plot (default: 1).

Value

A PCA plot

Author(s)

Takahiko Koizumi

Examples

data(Pinus)
train <- os.clean(Pinus$train)
target <- Pinus$target
os.pca(train, target)

Construct and apply the OmicSense model with your own data

Description

Construct and apply the OmicSense model with your own data

Usage

os.pred(x, y, newx = x, method = "linear", thresh = 0, n.pred = 0)

Arguments

x

A data matrix (row: samples, col: predictors).

y

A vector of target value.

newx

A data matrix (row: samples, col: predictors).

method

A string to specify the regression function for calculating R-squared values. "linear" (default), "quadratic" or "cubic" function can be specified.

thresh

The lower threshold of R-squared value to be leaved in prediction model (default: 0).

n.pred

The number of candidate predictors to be leaved in prediction model (default: 30).

Value

A vector of the environment in which the samples of newx were collected

Author(s)

Takahiko Koizumi

Examples

data(Pinus)
train <- os.clean(Pinus$train)
test <- Pinus$test
test <- test[, colnames(train)]
target <- Pinus$target
cor(target, os.pred(train, target, newx = test, method = "cubic"))

Visualize R-squared value distribution in target-predictor relationship

Description

Visualize R-squared value distribution in target-predictor relationship

Usage

os.rank(
  x,
  y,
  method = "linear",
  thresh = 0,
  n.pred = ncol(x),
  upper.xlim = ncol(x)
)

Arguments

x

A data matrix (row: samples, col: predictors).

y

A vector of target value.

method

A string to specify the regression function for calculating R-squared values. "linear" (default), "quadratic" or "cubic" function can be specified.

thresh

The lower threshold of R-squared value to be leaved in prediction model (default: 0).

n.pred

The number of predictors to be leaved in prediction model (default: ncol(x)).

upper.xlim

The upper limitation of x axis (i.e., the number of predictors) in the resulted figure (default: ncol(x)).

Value

A rank order plot

Author(s)

Takahiko Koizumi

Examples

data(Pinus)
train <- os.clean(Pinus$train)
target <- Pinus$target
train <- os.sort(train, target)
os.rank(train, target)

Sort and select predictors according to the strength of target-predictor relationship

Description

Sort and select predictors according to the strength of target-predictor relationship

Usage

os.sort(x, y, method = "linear", n.pred = ncol(x), thresh = 1)

Arguments

x

A data matrix (raw: samples, col: predictors).

y

A vector of target value.

method

A string to specify the regression function for calculating R-squared values. "linear" (default), "quadratic" or "cubic" function can be specified.

n.pred

The number of predictors to be leaved in prediction model (default: ncol(x)).

thresh

The lower threshold of R-squared value to be leaved in prediction model (default: 1).

Value

A data matrix (raw: samples, col: sorted predictors)

Author(s)

Takahiko Koizumi

Examples

data(Pinus)
train <- os.clean(Pinus$train)
target <- Pinus$target
cor(target, train[, 1])

train <- os.sort(train, target, thresh = 0.5)
cor(target, train[, 1])