drawSpec: Spectral plot

Description Usage Arguments Details Value Author(s) See Also Examples

Description

This function allows to draw a segment or the whole spectra with limited high/low bounds of intensity.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
drawSpec(X,
         startP = -1,
           endP = -1,
           groupLabel = NULL,
           useLog = -1,
           highBound = -1,
           lowBound = -1,
           xlab = NULL,
           ylab = NULL,
           main = NULL,
           nAxisPos = 4,
           offside = 0)

Arguments

X

The spectral dataset in matrix format in which each row contains a single sample.

startP

The starting point of the segment. If it is -1, the starting point is from begining of the spectra.

endP

The ending point of the segment. If it is -1, the ending point is the last point of the spectra.

groupLabel

The default value is NULL, it means that a single spectrum has a distinct color. Otherwise, the spectra is colored by their label.

useLog

The default value is -1, that means do not use a logarit transformation. If users want to transform the intensities to logarit values before ploting, set it to 1.

highBound

Default value is -1, that means the plot covers also the highest intesity peaks in the figure. If the users want to limit the upper height of the figure, set this parameter by the limited value.

lowBound

Default value is -1, that means the plot covers also the lowest intesity peaks in the figure. If the users want to limit the under height of the figure, set this parameter by the limited value.

xlab

The default value is NULL, if so, "index" is displayed at the horizontal axis.

ylab

The default value is NULL, if so, "intensity" is displayed at the vertical axis.

main

The default value is NULL, if so, the title shows the values of startP and endP

nAxisPos

The number of ticks that you want to display in horizontal axis.

offside

The offside of values in x-axis for display.

Details

This function allows to draw a segment or the whole spectra with limited high/low bounds of intensity.

Value

Return a plot of the spectra.

Author(s)

Trung Nghia Vu

See Also

drawBW

Examples

1
2
3
4
5
6
 
res=makeSimulatedData();
X=res$data;
groupLabel=res$label;

drawSpec(X)

nghiavtr/speaq documentation built on May 20, 2019, 5:27 p.m.