| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Bioinformatics Toolbox |
| Contents | Index |
| Learn more about Bioinformatics Toolbox |
SPCStruct = tgspcread(File)
tgspcread(..., 'ZRange', ZRangeValue,
...)
tgspcread(..., 'ScanIndices', ScanIndicesValue,
...)
tgspcread(..., 'Verbose', VerboseValue,
...)
SPCStruct = tgspcread(File) reads a Galactic SPC file from Thermo Scientific, and returns the data in a MATLAB structure.
tgspcread(..., 'PropertyName', PropertyValue, ...) calls tgspcread with optional properties that use property name/property value pairs. You can specify one or more properties in any order. Enclose each PropertyName in single quotation marks. Each PropertyName is case insensitive. These property name/property value pairs are as follows:
tgspcread(..., 'ZRange', ZRangeValue, ...) specifies a range of z data values in the SPC file from which to extract scans.
tgspcread(..., 'ScanIndices', ScanIndicesValue, ...) specifies a scan, multiple scans, or range of scans in the SPC file to read.
tgspcread(..., 'Verbose', VerboseValue, ...) controls the display of the progress of the reading of the SPC file. Choices are true or false (default).
File |
String specifying a file name or path and file name of an SPC file that conforms to the Thermo Scientific Universal Data Format Specification. If you specify only a file name, that file must be on the MATLAB search path or in the current directory. | |
ZRangeValue |
Two-element numeric array [Start End] that specifies the range of z data values in File to read. Start and End must be positive scalars, and Start must be less than End. Default is to extract all scans.
| |
ScanIndicesValue |
Positive integer, vector of integers, or a two-element numeric array [Start_Ind: End_Ind] that specifies a scan, multiple scans, or a range of scans in File to read. Start_Ind and End_Ind are each positive integers indicating a scan index. Start_Ind must be less than End_Ind. Default is to read all scans.
| |
VerboseValue |
Controls the display of the progress of the reading of File. Choices are true or false (default). |
SPCStruct |
Structure containing information from an SPC file. The structure contains the following fields.
|
The SPC file, results.spc, used in the following example is not provided with the Bioinformatics Toolbox software. You can download sample files from:
https://ftirsearch.com/default3.htm
Read an SPC file:
% Read the contents of an SPC file into a MATLAB structure
out = tgspcread('results.spc')
File contains 1 scans
out =
Header: [1x1 struct]
X: [12031x1 single]
Y: [12031x1 double]
Z: 0Plot an SPC file:
% Plot the first scan in the SPC file: plot(out.X,out.Y(:,1));
datenum | jcampread | mzcdf2peaks | mzcdfinfo | mzcdfread | mzxml2peaks | mzxmlinfo | mzxmlread | tgspcinfo
![]() | tgspcinfo | times (DataMatrix) | ![]() |

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |