Context-Merger
Table of Contents

Overview

This tool allows merging contexts that share exactly the same set of objects. All the contexts must be in RCF format.

Synopsis

Usage: ./pre05_contextMerger.sh [switch] <1st_db>  <2nd_db>  ...  <Nth_db>  [-of:output_file]

Options:
   -of:output_file       write result to output_file (default: stdout)

Parameters:
   <Nth_db>              the databases to be merged (must be in RCF format)

Example

First input:

# animals

[Relational Context]
Default Name
[Binary Relation]
Name_of_dataset
ostrich | canary | duck | shark | salmon | frog | crocodile
egg | feather | tooth | fly | swim | air
1 1 0 0 0 1
1 1 0 1 0 1
1 1 0 1 1 1
1 0 1 0 1 0
1 0 0 0 1 0
1 0 0 0 1 1
1 0 1 0 1 1
[END Relational Context]

Second input (to merge at the end of the first one):

# animals2

[Relational Context]
Default Name
[Binary Relation]
Name_of_dataset
ostrich | canary | duck | shark | salmon | frog | crocodile
gizzard | ossification
1 1
1 1
1 1
0 0
0 1
0 1
1 1
[END Relational Context]

Command:

./pre05_contextMerger.sh sample/animals.rcf sample/animals2.rcf

Output:

[Relational Context]
Default Name
[Binary Relation]
Name_of_dataset
ostrich | canary | duck | shark | salmon | frog | crocodile
egg | feather | tooth | fly | swim | air | gizzard | ossification
1 1 0 0 0 1 1 1
1 1 0 1 0 1 1 1
1 1 0 1 1 1 1 1
1 0 1 0 1 0 0 0
1 0 0 0 1 0 0 1
1 0 0 0 1 1 0 1
1 0 1 0 1 1 1 1
[END Relational Context]
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License