FILE

Import data

SENSABLE is able to import data in different formats if a few simple rules are followed as shown below:

 

MATLAB files

To import data from MATLAB the data must be arranged in a structure array named NoseData according to the following example:

 

Structure array name: NoseData

 

NoseData.data: data (sample × time × sensors) - I × J × K

NoseData.labels: cell array with three elements containing the labels of the three modes

NoseData.labels{1} = cell of length I that contains sample names (string)

NoseData.labels{2} = cell length J  (number)

NoseData.labels{3} = cell length K (string)

NoseData.mode  = {'Sample';'Time';'Sensor'};

NoseData.date: String with the date

NoseData.author = String with author name(s)

NoseData.name = String with name of data set (e.g. 'Off-flavour in fish')

NoseData.ref.data = y-data (I × M)

NoseData.ref.label = cell of length M that contains names of Y variables

 

 

If the structure array only contains NoseData.data the rest is automatically generated (see below), but can be edited.

 

NoseData.labels{1}(i) = i ...

NoseData.labels{2}(j) = j ....

NoseData.labels{3}(k) = k ....

NoseData.author = 'NA'

NoseData.name = 'NA'

NoseData.ref.data = [];

etc.

 

 

ASCII files

Importing data from an ASCII file (.txt) the following settings must be used. Use tabulates to separate numbers and decimal dots for non-integer numbers.

 

Data must be arranged in two dimensions with the third mode as the tabulate separated columns. The matricization of the data set as JI × K means that mode one and two are confounded and that the indices of mode two are running fastest. It is thus most convenient to set the time mode as mode two, as the time mode often contains the most variables.  

   

The headings in square brackets correspond to the names given in the MATLAB structure array. Example given for an electronic nose data set of 17 samples × 241 times × 11 sensors.

 

[DATASIZE]                       

17            241          11

 

[NAME OF MODES]                          

Samples

Times

Sensors

 

[DATE]                 

16-12-2003                            

                               

[AUTHOR]                           

Thomas Skov & Rasmus Bro                            

 

[NAME]                

Licorice evaluation                             

 

[DATA]                

338.34     571.26     240.91     307.15     43.95       53.02       29.47       62.71       30.92       63.33       56.25      

337.74     571.50     241.16     307.39     43.98       53.05       29.48       62.71       30.93       63.36       56.36

337.86     571.50     241.16     307.39     43.98       53.13       29.48       62.69       30.91       63.25       56.47      

337.86     571.02     240.91     307.15     44.01       53.02       29.47       62.67       30.92       63.33       56.58

337.62     576.58     241.16     307.51     44.77       53.02       29.48       62.67       30.92       63.31       56.78

338.22     598.37     241.16     308.84     46.88       53.07       29.47       62.67       30.9         63.25       56.86      

338.95     627.90     241.04     311.74     49.75       53.02       29.45       62.64       30.89       63.28       56.99      

340.77     655.25     241.52     316.09     52.34       53.00       29.44       62.67       30.89       63.36       57.01

 

[LABELS MODE1]                                                                                                                                                              

BAD-1                                                                                                                                                   

BAD-2                                                                                                                                                   

BAD-3                                                                                                                                                   

BAD-4

.

.

 

[LABELS MODE2]

1

2

3

4

5

.

.

 

[LABELS MODE3]

2

3

4

.

.

 

[REFDATA]                         

2              6              8

3              6              7

2              6              8

.

.

 

[LABELS REFDATA]                        

pH

Temperature

Volume

 

Save data

Data will be saved as a MATLAB file in a structure array named NoseData.

 

Export data

Data will be exported in ASCII format with the specifications listed for the import of ASCII files.

 

Save model

The model parameters are saved in MATLAB format with one structure array for the pre-processing (PreprocessedData) and one for the model (Model).

 

Export model

Data will be exported in ASCII format !!!!

 

Exit