defineKnots {ptairMS}R Documentation

Define the knots location

Description

defineKnots function determine the knots location for a ptrSet or ptrRaw object. There is three possibilities :

Usage

defineKnots(
  object,
  knotsPeriod = 3,
  method = c("expiration", "uniform", "manual")[1],
  knotsList = NULL,
  ...
)

## S4 method for signature 'ptrRaw'
defineKnots(
  object,
  knotsPeriod = 3,
  method = c("expiration", "uniform")[1],
  knotsList = NULL,
  timeLimit = list(NULL)
)

## S4 method for signature 'ptrSet'
defineKnots(
  object,
  knotsPeriod = 3,
  method = c("expiration", "uniform")[1],
  knotsList = NULL
)

Arguments

object

ptrSet object

knotsPeriod

the period in second (times scale) between two knots for the two dimensional modelization

method

expiration or uniform

knotsList

a list of knot location for each files, with all base name file in name of the list element

...

not used

timeLimit

index time of the expiration limits and background

Value

numeric vector of knots

a list with numeric vector of knots for each file

Examples

library(ptairData)
dirRaw <- system.file("extdata/exhaledAir", package = "ptairData")
exhaledPtrset <- createPtrSet(dir=dirRaw, setName="exhaledPtrset", 
mzCalibRef = c(21.022, 60.0525), fracMaxTIC = 0.7, saveDir = NULL )

#### placed knots every 2 times points
exhaledPtrset <- defineKnots(exhaledPtrset ,knotsPeriod=2,method='uniform')

#### placed knots every 3 times points in the expiration (default)
exhaledPtrset <- defineKnots(exhaledPtrset ,knotsPeriod=3,method='expiration')

[Package ptairMS version 1.1.5 Index]