Import Bean

The AbleImport bean provides access to data in text (flat) files. Import beans provide data to other beans through data buffer connections. Delimiter characters such as spaces, commas, or tabs can be used to separate fields. The delimiter string is passed to the Java StringTokenizer constructor and so can include more than one character.

Import beans are different from other AbleBeans because only one Import bean's data connection may be active at any given time. When an Import bean's data connection is turned ON, all other Import beans in the AbleAgent are turned OFF.

A file Import bean is a read-only file, and its layout is specified in a definition file. The Import file is managed by interfaces provided in AbleDataSource. A file can be read into memory either all at once or in blocks to conserve memory space. All buffering of the file data is handled by the AbleDataSource.

Some algorithms may use more than one bean as a data source, such as a neural network algorithm that uses one or more data sources for training and testing. These data sources must share the same record layout and field statistics so the same conversions are done on each record in each file.

Some algorithms benefit from presenting data in random sequence. For example, the weights of a back propagation neural network may tend to 'follow' the data if it is always presented in the same sequence. Randomizing the sequence helps the network train in this case. In other algorithms such as temporal difference learning, the sequence of records represents a series of steps from one state to another and the sequencing is critical to the algorithm.