FromFile

This block allows reading data from files, in particular, CSV, TAB, or TSV.

    FromFile

Library

Activate/SignalImporters

Parameters

FromFile_0

NameLabelDescriptionData TypeValid Values

fname

Filename

String

outsize

Data size

The output port size will be the same as the input file size.

If the data read from the file is less than the output size, initial value is used for the rest of output.

If the data read from the file is more than the output size, the extra read data from file is ignored.

Any character except numeric data i.e., ".dDeE+-0123456789" can be used as delimiter between numerical data. Only numerical data can be read from file.

The block reads the whole data stored in the file.

Matrix

vardatatype

Datatype

String

'double'
'int32'
'int16'
'int8'
'uint32'
'uint16'
'uint8'

Offset

Data starts from line #

Scalar

initial

Default value

Initial value is used for time instants before the activation of the block. Initial value can be either a scalar or a matrix.

Matrix

Ports

NameTypeDescriptionIO TypeNumber

Port 1

explicit

output

1

Port 2

activation

input

1