Difference between revisions of "Component Guide 5: Displays and Controls"
|Line 37:||Line 37:|
;Properties: Right-click to view and set Table properties.
;Properties: Right-click to view and set Table properties.
Revision as of 17:25, 7 January 2015
A Graph display is used to display results of a simulation. A Graph has the capability to display multiple series / variables simultaneously. You can also compare the results of different simulations on the same graph.
Usage: To add a Graph to a model, select the Graph tool in the component palette and then click on either the model canvas or the dashboard. Two objects will appear – a graph stub on the model canvas, and the graph display on the dashboard. The graph display and stub are linked, like two sides of the same coin. They don’t move together, but they represent the same graph object. The purpose of the stub on the model canvas is to provide a way to connect the graph to other objects in the model and set its properties. You can have multiple graph objects in one model, and you can have graph objects on different levels of a multi-level model. In addition, a graph display can have multiple pages or tabs. All graph stubs look identical, but you can tell them apart by looking at the name. The graph display in the dashboard can be resized by grabbing the little handle on the bottom right.
- Right-click to view and set graph properties.
- Graph Title. Enter a title for the graph, which will appear next to it on both the model canvas as well as the dashboard.*
- Page size. Set the number of pages (or tabs) in the graph.
- Page. Pick the graph page/tab to customize, starting with 0 for the first page. For example, if a graph object has 2 pages (Page size = 2), then the numbers in Page will be either 0 or 1. When Page=0, you are changing the Properties for the first page / tab. When you change Page=1, now the property shown are for the second page.
- Pin button. If the pushpin button is depressed, the graph will always appear on the dashboard at every level above the current level. This is only relevant if the Nova project has more than one level.
- Refresh rate. The refresh date determines the number of time steps between redraws of the graph. With the default value 1, the graph is refreshed at every time step.
- Display. Enter the first and last time to display on the graph. In a time series graph, time appears on the x-axis
- Full Time Interval. If checked graph display entire interval specified by Display
- Graph Type. Select the type of graph: time series, scatter, bar, or 3D scatter [Currently unavailable]. If the graph type is ‘Scatter’, the ‘Connect Dots’ checkbox will be enabled so you can decide whether or not to connect the dots.
- Select Contents. The box on the left lists all of the model objects that can be plotted on the graph (objects don’t have to be connected with an arrow). Icons indicate what type of object (term, stock, etc.) each variable is. Select one or more variables and click the >>> button to put them in the list of series that will be display on the right. To remove a variable from the graph, select the variable name in the right-hand pane and click the <<< button. Then lick ‘OK’.
- Color picker. To change the color for a series in the Graph, select the name of the variable in the right-hand pane, then click the color picker (sample color next to ‘Scale’).
- Scale / Low / High. These properties determine the range of the y-axis. The default setting for ‘Scale’ is ‘Auto’, meaning the graph object will select the upper and lower bounds for the y-axis based on the data. If more than one variable / series is plotted, each variable will have its own individually scaled y-axis (even if the data ranges are nearly identical). To manually enter low and high values for an individual variable, click on the name of the variable in the right-hand pane. If the model has run already, the low and high values for this variable will appear in the boxes on the bottom. Change the scale to ‘Self’, and then enter values for the Low and High values click “Set” to save the changes.
- Alias. The alias is the label that will appear in the legend. To change the alias, click on one of the variables in the graph in the right-hand pane, type in an Alias, then click ‘Set’.
- Graph Display
- Normal / compare. Graph displays have two modes. In ‘normal’ mode, each time the model is run the graph is redrawn. In ‘compare’ mode, each time the model is run the new data is plotted on the graph but the previous data is not erased. If the y-axis scale is set to ‘auto’, data already on the graph will be redrawn to fit the new scale. To erase the graph contents in either compare or normal mode, click the ‘Load’ button.
- Save data. Click this button to save the data in the graph to a csv file.
- Identifying exact values. After a model has been run, exact values on the display can be viewed by clicking in the graph area and moving the mouse to the desired point on the horizontal axis.
- Zooming. Zoom in on the graph by highlighting the portion of the graph you wish to see with the mouse. [How to zoom out?]
Graph objects don’t have to be manually connected to other objects in the model with an arrow. Once an object has been setup for display in a graph, a dotted line will be drawn to illustrate which object the graph is displaying. If you want to display the results of a mathematical expression (e.g., the sum of two stocks), add a Term object with the expression and then display the Term object in the Graph.
A Table operates much like a Graph, but instead of visually showing results as the model runs a Table returns the actual numbers. These numbers can be exported to a csv file for further analysis.
Usage: To add a Table display to a model, select the Table tool from the component palette and then click on eitherthe model canvas or the dashboard where you want the table to appear. Two objects will appear – a table icon on the model canvas, and the Table display on the dashboard. The Table icon and display don’t move together but they represent the same Table object. The purpose of the icon on the model canvas is to provide a way to see which objects are displayed in Table, and to set its properties. You can have more then one table display in a model, and a single Table display can show the outputs of several objects in the model. The table display in the dashboard can be resized by grabbing the little handle on the bottom right.
- Right-click to view and set Table properties.