This is the default constructor for a dataframe object, which is
similar to R ’data.frame’. It’s a way to group tabular data, then
accessing them either as matrix or by column name.
Input argument x may be:
- a dataframe => use varargin to pad it with suplemental
columns
- a matrix => create column names from input name; each column
is used as an entry
- a cell matrix => try to infer column names from the first row,
and row indexes and names from the two first columns;
- a file name => import data into a dataframe;
- a matrix of char => initialise colnames from them.
- a two-element cell: use the first as column as column to
append to, and the second as initialiser for the column(s)
If called with an empty value, or with the default argument, it
returns an empty dataframe which can be further populated by
assignement, cat, ... If called without any argument, it should
return a dataframe from the whole workspace.Variable input arguments are first parsed as pairs (options, values).
Recognised options are:
- rownames : take the values as initialiser for row names
- colnames : take the values as initialiser for column names
- seeked : a (kept) field value which triggers start of processing.
- trigger : a (unkept) field value which triggers start of processing.
- datefmt: date format, see datestr help
Each preceeding line is silently skipped. Default: none
- unquot: a logical switch telling wheter or not strings should
be unquoted before storage, default = true;
- sep: the elements separator, default ’\t’, ’,’
- conv: some regexp to convert each field. This must be a
two-elements cell array containing regexprep() second (PAT)
and third (REPSTR) arguments. In order to replace ’,’ by ’.’,
use ’{’,’, ’.’}’. In this case, the default separator is adjusted to ’\t;’
The remaining data are concatenated (right-appended) to the existing ones.