Data: Difference between revisions

From Planimate Knowledge Base
Jump to navigation Jump to search
mNo edit summary
No edit summary
 
Line 1: Line 1:
== Data: Attributes Tables and Lists  ==
Planimate has a few fundamental types for storing information in a model.<br>


Attribute is a general term used in Planimate® to denote a characteristic that belongs to some component or aspect of a dynamic system model. When you build a model, the Attribute is given a value. Attributes are an essential part of your description of a system model. Objects, individual items, item classes, Sub-systems and the overall system model can have identifiable attributes.  
[[Attribute|Attributes]] store a single value or string of text and are useful for key parameters, constants and control variables in routine code. They can be formatted to a number of different in-built formats which are used during data input and display.<br>


The value of an Attribute can remain constant during the course of a model run, or be dynamic. Some Attributes are generally available to the model. This means that their values can be referred to and read by objects.  
[[Table|Tables]] consist of rows and columns, with each column having a different format assignable. As well as storing data, tables are the data source for a number of different [[Table_View|table views]] including graph plots.<br>


Attributes are listed and edited in various places in your model. You specify your references to them from other locations. The key means of referring to attributes is the Attribute Selection Dialog. The key means of changing attribute values is either via a Routine in a Change Object, or through the binding of an Attribute to an Object.
[[Label_List|Label Lists]] are a collection of name/value pairs and are useful for defining sets of identifiers (eg:&nbsp;location names). Attributes and Table Columns can be formatted to indicate their data are members of a label list. Planimate exposes many internal label lists to facilitate its advanced [[Routine_Operations|routine operations]].<br>
 
== Uses For Attributes ==
 
Here are a number of uses for attributes:
 
*To record information in simple or specialized way, and perform summaries or aggregations that are not directly available from the logging of individual object attributes.
*To control the behaviour of the model by informing switch objects where (or when) items should be directed to go.
*To control the capacity or behaviour of individual objects in the model.
*To scale the value of average figures and distributions used in interaction parameter specifications.
*To combine the above capabilities and produce sophisticated mechanisms for monitoring and controlling the behaviour of the system.
 
All of the above uses involve attribute values that can remain static, or change over time.
 
 
 
=== Uses for Portal Attributes  ===
 
Portal Attributes can be used to describe the history or present state of one part of a model, a region of a model or the whole of a model. Portal Attributes can keep track of system conditions like availability of clerks, or the utilisation of power in one region of an electrified railroad network.
 
A Portal Attribute can be used to create links between parts of your model that are not directly linked by item flows.
 
For example, a Portal Attribute may specify the number of machines available in a work cell, as well as the number of required operators. Another use of a Portal Attribute is to monitor or control the number of non-renewable resources circulating around in a system.
 
=== Distinguishing between the Uses of Attributes ===
 
In Planimate® modelling, we distinguish between attributes used within the model, and attributes that you enter from outside the model for a particular model run, which are called parameters.
 
Parameters are values which are entered into the description of a system model from the "outside". That is to say you assign some parameter values for a particular system scenario. You then perform experiments with the resulting model by altering these parameters.
 
The experiments you perform are called "Parametric Studies", "Sensitivity Analyses" and "Capacity Studies". These experiments examine changes in system performance that result from varying one or more parameters.
 
Parameters need to enter the system model somewhere. They can be inserted as static attributes of one or more system entities, as Portal, Item, Class, or Table Attribute values. Discerning the distinctions between various kinds of attributes, and parameters will enable you to make more effective use of Planimate® and to better organize your view of the required data of a system.
 
 
 
== Fixed vs. Dynamic Attributes ==
 
You can specify fixed and dynamic attributes for things (entities) in your system.
 
A fixed attribute of an entity remains constant, and the behaviour of the entity with respect to that attribute remains constant throughout the model run. This kind of attribute is only referenced, not overwritten.
 
In contrast, dynamic attributes collect information about, or influence the behaviour of an entity in a variable manner during the model run. This kind of attribute may be referenced, however it may also be overwritten and updated during the model run.
 
For example, a dynamic attribute may keep track of how many kilometres a locomotive has run since its last major maintenance, or it may keep track of how many defective paint jobs have just appeared in sequence.
 
Some attributes of objects can change over time as a result of preset schedules, such as the capacity of a multi-server. This could, for example, represent the number of part-time tellers available at different times of the day, in a bank branch. Statistics gathered for an object are in fact really registering dynamic attributes for that object.
 
 
 
== Attributes and Patterns of Variation ==
 
Patterns of variation (distributions) describe the expected variability of some attribute. Patterns of variation are used in Interaction Editing to describe the processing delays which occur for items. Planimate® has a mechanism which enables a pattern of variation, including its mean and any other necessary " parameters ", to be used in the same manner as an actual numeric constant.
 
Each time a pattern of variation is referenced (sampled), it delivers a value different from the previous reference. Because the PATTERN of variation used (sampled) is the same each time, it can be regarded as a CONSTANT attribute when used with an entity.
 
You can use the Attribute Referencing capability of a Distribution Dialog to determine its components based on the varying value of an attribute. You can specify a constant or variable average value for an interaction parameter, and have its average and deviation (if any) scaled by the value of an attribute, which may itself carry a degree of variation.
 
 
 
== Attribute Limitations ==
 
It is tempting in some circumstances to use combinations of attributes to describe and manage complex conditions within a model. In effect, it becomes possible to do a fair degree of "programming" by effectively using a number of Item Attributes and Portal Attributes.
 
Although the use of attributes provides a feasible means of handling many complex situations, its effective use requires more than just Change Objects in a " Black Box " sub-system. You need to provide a friendly Black Box.
 
This requires the skill of an experienced Planimate® modeller familiar with all of the tools available in Planimate® for creating effective and communicative models. Complicated management and control structures using attributes should be made as transparent as possible, particularly for the benefit of those users who wish only to consult a model AFTER it has been built.
 
It is recommended that you maintain the visual style of Planimate®, by ensuring that these control areas are kept at low levels of the system model, well laid out, and easy to follow.
 
 
 
== Modifying Attributes  ==
 
Attributes can be changed when an item passes through a Change object. Attributes can dynamically control interaction times for any delay, and also the behaviour of Switches, MultiServers, DropOffs and PickUps during a model run. The application of Attributes in this fashion enables wide-ranging and complex system control and management structures to be simulated. Attributes can also collect details about the logical behaviour of your model and present them as on-screen and/or logged statistics.
 
Changes to an Item Attribute occur as the item passes through the Change Object, and affects only that individual Item’s Attribute Value. Changes to a Portal, System, Class or Table Attribute occur as the item passes through the Change, and its new value is communicated at that time to any object that makes reference to that Attribute.
 
Changes to Attributes can be specified through the use of a range of operations that are entered into the Change. Any of these operations can use a Constant value, or an Attribute, or Table for reference. When Routine is selected from the Change's Object Edit Menu, a menu appears, enabling you to add a new calculation. If you have already entered some calculations, the menu becomes a list enabling you to add a new calculation, or modify an existing calculation.
 
== Writing Attributes to a File ==
 
There are a number of options for data transfer using a Change Object. Data can be both imported and exported during a Model Run. The exported data comprises the current value of selected attributes, and Tables. Imported Data is assigned to various Attributes, or Tables.
 
You can select the Attributes that you wish to write, using Attribute Selection Dialog.
 
Any item passing through a Change Object set up for Data Exchange triggers a Data Exchange event.
 
For details on implementing Data Exchange, refer to &lt;Data Connectivity and Integration&gt;.


[[Item|Item Classes]] can have a number of item and table pointers assigned to them, as well as being able to carry other items. This makes them a type of data in Planimate as well Through a process that is called [[Tupling|Tupling]] in Planimate, an item can transfer its attributes to a row in a table where columns have matching names.<br>


[[DataSet|DataSet]] is a system for loading and saving data in a Planimate model featuring compression, encryption and mechanisms to cope with an evolving model.<br>


== Data Connectivity and Integration  ==
== Data Connectivity and Integration  ==
Line 101: Line 15:
The Planimate® Platform currently supports a variety of data transfer mechanisms:  
The Planimate® Platform currently supports a variety of data transfer mechanisms:  


- [[ODBC_Data_Exchange|Open Database Connectivity (ODBC)]] connectivity to and from a wide range of data sources like DB/Spreadsheet etc.  
- [[ODBC Data Exchange|Open Database Connectivity (ODBC)]] connectivity to and from a wide range of data sources like DB/Spreadsheet etc.  


- [[Select File Transfer Mode|Reading and Writing of Plain Text]] files (tab delimited, comma separated, HTML)  
- [[Select File Transfer Mode|Reading and Writing of Plain Text]] files (tab delimited, comma separated, HTML)  


- [[TCP/IP_Sockets_Editor|TCP/IP Data Packet]] transmission (XML formatted) through Client and Server Sockets and ports.  
- [[TCP/IP Sockets Editor|TCP/IP Data Packet]] transmission (XML formatted) through Client and Server Sockets and ports.  


- [[Serving_web_pages_and_responding_to_HTTP_requests|HTTP request processing]] (Web Enablement) and URL fetching.
- [[Serving web pages and responding to HTTP requests|HTTP request processing]] (Web Enablement) and URL fetching.  


== Data Exchange during a Model Run ==
== Data Exchange during a Model Run ==


Data can be both imported and exported during a Model Run. The exported data comprises the current value of selected attributes, and Tables. Imported Data is assigned to various Attributes, or Tables. You can select the Attributes that you wish to write, using the Attribute Selection Dialog.  
Data can be both imported and exported during a Model Run. The exported data comprises the current value of selected attributes, and Tables. Imported Data is assigned to various Attributes, or Tables. You can select the Attributes that you wish to write, using the Attribute Selection Dialog.  
Line 115: Line 29:
Any item passing through a Change Object set up for Data Exchange triggers a Data Exchange event. There are a number of options for data transfer using a Change Object.  
Any item passing through a Change Object set up for Data Exchange triggers a Data Exchange event. There are a number of options for data transfer using a Change Object.  


Data can also be loaded and saved using Planimate®’s own DataSet features. This can be done during a Model Run, either manually from under File in the Menu Bar, or under the control of the Model itself using Routine operations.
Data can also be loaded and saved using Planimate®’s own DataSet features. This can be done during a Model Run, either manually from under File in the Menu Bar, or under the control of the Model itself using Routine operations.  


<br>


== Clipboard Handling in Planimate®  ==


== Clipboard Handling in Planimate® ==
Individual Text strings or numeric values can be copied and pasted using the usual Ctrl-C and Ctrl-V access to the Clipboard.


Individual Text strings or numeric values can be copied and pasted using the usual Ctrl-C and Ctrl-V access to the Clipboard.
Table Cells or Selections can be copied to the Clipboard using the Right-Click context menu on a table cell or selection. Copied table data is put into the Windows clipboard when another application is brought to the foreground. (e.g. Using Alt-Tab). Tables copied to the Clipboard include their Column Headings, for convenience. The data is Text and is formatted as seen in the Table Cells.  


Table Cells or Selections can be copied to the Clipboard using the Right-Click context menu on a table cell or selection. Copied table data is put into the Windows clipboard when another application is brought to the foreground. (e.g. Using Alt-Tab). Tables copied to the Clipboard include their Column Headings, for convenience. The data is Text and is formatted as seen in the Table Cells.
<br>


=== Pasting Data into Tables from the Clipboard  ===


You can use the windows clipboard to copy data into tables in Planimate.


=== Pasting Data into Tables from the Clipboard ===
This is done from the Table Editor Window Menu Bar via File / Import from Clipboard or from a Cell/Selection context menu "Import from Clipboard" option. These only appear if there is data in the clipboard.


You can use the windows clipboard to copy data into tables in Planimate.
Note that only entire Tables may be Imported - partial Table import from Clipboard is not supported.  


This is done from the Table Editor Window Menu Bar via File / Import from Clipboard or from a Cell/Selection context menu "Import from Clipboard" option. These only appear if there is data in the clipboard.
<br>


Note that only entire Tables may be Imported - partial Table import from Clipboard is not supported.
=== Setting Clipboard Defaults ===
 
 
 
=== Setting Clipboard Defaults ===


In the Table Editor Window under File in its menu bar, you can specify some defaults that will determine what data is transferred to and from the clipboard.  
In the Table Editor Window under File in its menu bar, you can specify some defaults that will determine what data is transferred to and from the clipboard.  


Configure Clipboard Import Defaults You can choose default options to apply to Data Import from the Clipboard. Various options can be selected.
Configure Clipboard Import Defaults You can choose default options to apply to Data Import from the Clipboard. Various options can be selected.  
 
Configure Clipboard Export Defaults You can choose default options to apply to Data being copied to the Clipboard from this table. Various options can be selected.
 
 


== Planimate® Interoperability ==
Configure Clipboard Export Defaults You can choose default options to apply to Data being copied to the Clipboard from this table. Various options can be selected.


Planimate® has been successfully used as a back end application, activated through web applications. Users enter data through their Internet Browser, which is processed through a script. The Planimate®-Based Application (PBA) is called and run, and outputs are returned in tabular and graphical form via the script.
<br>


InterDynamics has also developed an API for the creation of DLL's that can extend the capabilities of a PBA in specific areas, making its ultimate functionality open-ended.
== Planimate® Interoperability  ==


The above features magnify the potency of competitive advantage derived from the adoption and use of PBA’s. PBA’s are not limited to the individual workstation. PBA’s can comfortably reside and operate reliably in a larger IT environment, and can obtain, process and deliver information to multiple users throughout the organisation, operating in interactive graphical, or engine-like modes.
Planimate® has been successfully used as a back end application, activated through web applications. Users enter data through their Internet Browser, which is processed through a script. The Planimate®-Based Application (PBA) is called and run, and outputs are returned in tabular and graphical form via the script.  


InterDynamics has also developed an API for the creation of DLL's that can extend the capabilities of a PBA in specific areas, making its ultimate functionality open-ended.


The above features magnify the potency of competitive advantage derived from the adoption and use of PBA’s. PBA’s are not limited to the individual workstation. PBA’s can comfortably reside and operate reliably in a larger IT environment, and can obtain, process and deliver information to multiple users throughout the organisation, operating in interactive graphical, or engine-like modes.


== Web Enablement of PBA's ==
<br>


Planimate® Data Exchange options enable the acceptance of data inputs via HTML forms, and the presentation of outputs, in tabular and graphical form via either HTML tables, or JPG/GIF images, suitably converted and processed through the ASP script. Planimate® is also capable of directly outputting textual/numeric data pre-formatted as HTML.
== Web Enablement of PBA's  ==


Planimate® Data Exchange options enable the acceptance of data inputs via HTML forms, and the presentation of outputs, in tabular and graphical form via either HTML tables, or JPG/GIF images, suitably converted and processed through the ASP script. Planimate® is also capable of directly outputting textual/numeric data pre-formatted as HTML.


<br>


=== Data Format ===
=== Data Format ===


The sockets will carry streams of 8 bit ASCII clear text. Planimate® will send and expect broadcast “packets” formatted in an XML based format.  
The sockets will carry streams of 8 bit ASCII clear text. Planimate® will send and expect broadcast “packets” formatted in an XML based format.  


A packet will look like this:
A packet will look like this:  


&lt;planimate version=”4.24”&gt;
&lt;planimate version=”4.24”&gt;  


&lt;model name=”model name”
&lt;model name=”model name”  


time=”1 Jan 2001 00:00:00”/&gt;
time=”1 Jan 2001 00:00:00”/&gt;  


&lt;broadcast
&lt;broadcast  


_name=”broadcast-name”
_name=”broadcast-name”  


_class=”item-class”  
_class=”item-class”  


_format="raw"&gt;
_format="raw"&gt;  


&lt;attributes  
&lt;attributes  


attribute1=”label1”
attribute1=”label1”  


attribute2=”12345”
attribute2=”12345”  


attribute3=”0.05”
attribute3=”0.05”  


attribute4=”misc info 1”/&gt;
attribute4=”misc info 1”/&gt;  


&lt;/broadcast&gt;
&lt;/broadcast&gt;  


&lt;/planimate&gt;
&lt;/planimate&gt;  


A separate packet is sent for every model broadcast associated with a socket. Upon receiving a valid packet, Planimate® will generate a broadcast and use “tupling” to set the attributes of the target class to any matching attribute available in the packet.
A separate packet is sent for every model broadcast associated with a socket. Upon receiving a valid packet, Planimate® will generate a broadcast and use “tupling” to set the attributes of the target class to any matching attribute available in the packet.  


format="raw” specifies the attribute values are unformatted values
format="raw” specifies the attribute values are unformatted values  


format="normal" is the default and specifies formatted values
format="normal" is the default and specifies formatted values  


A received broadcast will have the values processed as determined by the value/presence of this tag. A broadcast can be sent with unformatted values by adding "2" to the "use item" field in the change object "broadcast" routine operation (ie: the value should be 3 instead of 1 to cause attributes to be sent without any formatting).
A received broadcast will have the values processed as determined by the value/presence of this tag. A broadcast can be sent with unformatted values by adding "2" to the "use item" field in the change object "broadcast" routine operation (ie: the value should be 3 instead of 1 to cause attributes to be sent without any formatting).  


<br>


== Debugging Attributes in Models  ==


== Debugging Attributes in Models ==
Portal Attributes are capable of capturing information from, and also informing, a number of different model components simultaneously. It could be that the information currently held by a Portal Attribute is incorrect for some of the components. This raises the issue of the ordering of Portal Attribute operations.


Portal Attributes are capable of capturing information from, and also informing, a number of different model components simultaneously. It could be that the information currently held by a Portal Attribute is incorrect for some of the components. This raises the issue of the ordering of Portal Attribute operations.
Using the Pause at Events Debugging Option to perform Event Stepping becomes extremely slow and frustrating in a large model.  


Using the Pause at Events Debugging Option to perform Event Stepping becomes extremely slow and frustrating in a large model.
Instead, use the on-screen display features of attributes to provide an " on the spot " explanation of the " unseen " activity of the Model.  


Instead, use the on-screen display features of attributes to provide an " on the spot " explanation of the " unseen " activity of the Model.
Where conflicting operations occur simultaneously in a model using attributes to control or regulate various aspects, strange model behaviour may be difficult to track down.  


Where conflicting operations occur simultaneously in a model using attributes to control or regulate various aspects, strange model behaviour may be difficult to track down.
The most easily addressed solution to this problem is to keep control mechanisms and attribute references local to one area. You still have the same challenge, but limiting it to one screen makes maintaining the model easier.<br><br>


The most easily addressed solution to this problem is to keep control mechanisms and attribute references local to one area. You still have the same challenge, but limiting it to one screen makes maintaining the model easier.<br><br>
[[Category:Attribute]] [[Category:Data]] [[Category:Debugging]] [[Category:Table]]


[[Category:Training]]
[[Category:~TBD]]
[[Category:Data]]
[[Category:Attribute]]
[[Category:Attribute]]
[[Category:Data]]
[[Category:Debugging]]
[[Category:Table]]
[[Category:Table]]

Latest revision as of 20:54, 5 December 2012

Planimate has a few fundamental types for storing information in a model.

Attributes store a single value or string of text and are useful for key parameters, constants and control variables in routine code. They can be formatted to a number of different in-built formats which are used during data input and display.

Tables consist of rows and columns, with each column having a different format assignable. As well as storing data, tables are the data source for a number of different table views including graph plots.

Label Lists are a collection of name/value pairs and are useful for defining sets of identifiers (eg: location names). Attributes and Table Columns can be formatted to indicate their data are members of a label list. Planimate exposes many internal label lists to facilitate its advanced routine operations.

Item Classes can have a number of item and table pointers assigned to them, as well as being able to carry other items. This makes them a type of data in Planimate as well Through a process that is called Tupling in Planimate, an item can transfer its attributes to a row in a table where columns have matching names.

DataSet is a system for loading and saving data in a Planimate model featuring compression, encryption and mechanisms to cope with an evolving model.

Data Connectivity and Integration

The Planimate® Platform currently supports a variety of data transfer mechanisms:

- Open Database Connectivity (ODBC) connectivity to and from a wide range of data sources like DB/Spreadsheet etc.

- Reading and Writing of Plain Text files (tab delimited, comma separated, HTML)

- TCP/IP Data Packet transmission (XML formatted) through Client and Server Sockets and ports.

- HTTP request processing (Web Enablement) and URL fetching.

Data Exchange during a Model Run

Data can be both imported and exported during a Model Run. The exported data comprises the current value of selected attributes, and Tables. Imported Data is assigned to various Attributes, or Tables. You can select the Attributes that you wish to write, using the Attribute Selection Dialog.

Any item passing through a Change Object set up for Data Exchange triggers a Data Exchange event. There are a number of options for data transfer using a Change Object.

Data can also be loaded and saved using Planimate®’s own DataSet features. This can be done during a Model Run, either manually from under File in the Menu Bar, or under the control of the Model itself using Routine operations.


Clipboard Handling in Planimate®

Individual Text strings or numeric values can be copied and pasted using the usual Ctrl-C and Ctrl-V access to the Clipboard.

Table Cells or Selections can be copied to the Clipboard using the Right-Click context menu on a table cell or selection. Copied table data is put into the Windows clipboard when another application is brought to the foreground. (e.g. Using Alt-Tab). Tables copied to the Clipboard include their Column Headings, for convenience. The data is Text and is formatted as seen in the Table Cells.


Pasting Data into Tables from the Clipboard

You can use the windows clipboard to copy data into tables in Planimate.

This is done from the Table Editor Window Menu Bar via File / Import from Clipboard or from a Cell/Selection context menu "Import from Clipboard" option. These only appear if there is data in the clipboard.

Note that only entire Tables may be Imported - partial Table import from Clipboard is not supported.


Setting Clipboard Defaults

In the Table Editor Window under File in its menu bar, you can specify some defaults that will determine what data is transferred to and from the clipboard.

Configure Clipboard Import Defaults You can choose default options to apply to Data Import from the Clipboard. Various options can be selected.

Configure Clipboard Export Defaults You can choose default options to apply to Data being copied to the Clipboard from this table. Various options can be selected.


Planimate® Interoperability

Planimate® has been successfully used as a back end application, activated through web applications. Users enter data through their Internet Browser, which is processed through a script. The Planimate®-Based Application (PBA) is called and run, and outputs are returned in tabular and graphical form via the script.

InterDynamics has also developed an API for the creation of DLL's that can extend the capabilities of a PBA in specific areas, making its ultimate functionality open-ended.

The above features magnify the potency of competitive advantage derived from the adoption and use of PBA’s. PBA’s are not limited to the individual workstation. PBA’s can comfortably reside and operate reliably in a larger IT environment, and can obtain, process and deliver information to multiple users throughout the organisation, operating in interactive graphical, or engine-like modes.


Web Enablement of PBA's

Planimate® Data Exchange options enable the acceptance of data inputs via HTML forms, and the presentation of outputs, in tabular and graphical form via either HTML tables, or JPG/GIF images, suitably converted and processed through the ASP script. Planimate® is also capable of directly outputting textual/numeric data pre-formatted as HTML.


Data Format

The sockets will carry streams of 8 bit ASCII clear text. Planimate® will send and expect broadcast “packets” formatted in an XML based format.

A packet will look like this:

<planimate version=”4.24”>

<model name=”model name”

time=”1 Jan 2001 00:00:00”/>

<broadcast

_name=”broadcast-name”

_class=”item-class”

_format="raw">

<attributes

attribute1=”label1”

attribute2=”12345”

attribute3=”0.05”

attribute4=”misc info 1”/>

</broadcast>

</planimate>

A separate packet is sent for every model broadcast associated with a socket. Upon receiving a valid packet, Planimate® will generate a broadcast and use “tupling” to set the attributes of the target class to any matching attribute available in the packet.

format="raw” specifies the attribute values are unformatted values

format="normal" is the default and specifies formatted values

A received broadcast will have the values processed as determined by the value/presence of this tag. A broadcast can be sent with unformatted values by adding "2" to the "use item" field in the change object "broadcast" routine operation (ie: the value should be 3 instead of 1 to cause attributes to be sent without any formatting).


Debugging Attributes in Models

Portal Attributes are capable of capturing information from, and also informing, a number of different model components simultaneously. It could be that the information currently held by a Portal Attribute is incorrect for some of the components. This raises the issue of the ordering of Portal Attribute operations.

Using the Pause at Events Debugging Option to perform Event Stepping becomes extremely slow and frustrating in a large model.

Instead, use the on-screen display features of attributes to provide an " on the spot " explanation of the " unseen " activity of the Model.

Where conflicting operations occur simultaneously in a model using attributes to control or regulate various aspects, strange model behaviour may be difficult to track down.

The most easily addressed solution to this problem is to keep control mechanisms and attribute references local to one area. You still have the same challenge, but limiting it to one screen makes maintaining the model easier.