readASD {prospectr} | R Documentation

## Read ASD FieldSpec Pro binary and ASCII files

### Description

Read single or multiple binary and ASCII files acquired with an ASD FieldSpec Pro (ASDi, Boulder, CO) spectroradiometer

### Usage

    readASD(fnames,in_format,out_format)

### Arguments

`fnames` | character `vector` of the name(s) (with absolute path) of the file(s) to read
`in_format` | format of the input file: `'binary'` or `'txt'`
`out_format` | format of the output: `'matrix'` (default) or `'list'` (see below)

### Value

if `out_format` = `'matrix'`, reflectance values of the input file(s) in a single `matrix`.

if `out_format` = `'list'`, a `list` of the input file(s) data consisting of a `list` with components:

- `Name` name of the file imported

- `datetime` date and time of acquisition in `POSIXct` format

- `header` `list` with information from the header file

- `radiance` if applicable, a numeric `vector` of radiance values

- `reference` if applicable, a numeric `vector` of radiance values of the white reference

- `reflectance` numeric `vector` of reflectance values

- `wavelength` numeric `vector` of the band positions

### Note

The is a R port of the ‘importasd.m’ function from the ‘FSFPostProcessing’ Matlab toolbox by Iain Robinson (University of Edinburgh), which is based on some Java code provided by Andreas Hunei (University of Zurich)

It seems that ASD file format has changed quite a lot with file versions. The function will possibly not work as expected for all versions. Please report any bugs to the package maintainer.

### Author(s)

Antoine Stevens (R port) and Iain Robinson (matlab function)

### References

http://fsf.nerc.ac.uk/user_group/user_group.shtml

http://www.mathworks.com/matlabcentral/fileexchange/31547

Indico Version 8 file format (http://support.asdi.com/Document/Documents.aspx)

[Package prospectr version 0.1.3 Index]