|Top Previous Next|
The PlotWindow object displays graphical data in either a Cartesian or polar coordinate system, with monitor mode turned on or off.
Create PlotWindows in FreeFlyer Script
PlotWindows can be created in FreeFlyer script. The following list displays a few of the features of the PlotWindow Object that are available in script.
The following examples show how to create and edit PlotWindows in script.
Create a PlotWindow
The script example below shows how to create a PlotWindow via FreeFlyer script and customize its x- and y-axis labels.
Update a PlotWindow
When a PlotWindow is created with data series, the PlotWindow can be updated using the Update command at any point in the Mission Sequence.
When a PlotWindow is created without attaching an data series, the user can add data series (or data points) at any time in the Mission Sequence and the PlotWindow will be updated.
Set PlotWindow Properties
The user can change all plot properties via FreeFlyer script. For example, the font type, color, size and text of the plot title and subtitle can be edited. There are options to customize the legend: show or hide the legend, set a legend title, choose the legend location, and show or hide the border. The x- and y-axis labels and formats can be set. The line type, color and other properties can also be set. The syntax example below displays a few of the these options.
Set Font Properties
As mentioned above, the user can set the font type for any of the string properties (title, subtitle, axis labels, etc.) on the PlotWindow Object. The syntax example below displays how to set the font type and style of the PlotTitle of PlotWindow1.
If the user selects a font typeface (Arial, Times New Roman, Verdana, etc.) that is not available on their computer, FreeFlyer will revert to the previous font selected for the specified property. If the previous font is not available, FreeFlyer will use the default font typeface of the specified property. If the font typeface exists, but the style (combination of the bold, italic, underline, strikeout properties) is not available, FreeFlyer will try to select the closest match to the desired font typeface and style.
Axis Label Properties
You can set the format of the axis labels in FreeFlyer script or the PlotWindow Properties user interface. The formatting follows all of .NET's numeric and date/time format string options. The syntax to set the label format is shown below.
The table below displays a few available options for setting the labels format and the associated output.
The user can set the axis to use date and time formatting for the labels using the syntax below.
The default value of the UseDateTimeFormatting property is false, meaning that the axis content will not use the date and time format. When the axis content is an epoch, UseDateTimeFormatting is automatically turned on.
Note: It is important for the LabelsFormat property to correspond to the UseDateTimeFormatting flag. For example, if the user sets the LabelsFormat to use scientific notation ("e"), the UseDateTimeFormatting flag should be set to false (0) for the desired results.
Data Label Properties
You can turn on data labels and choose the label style for each plot scatter series in the plot as shown below. For example, the labels can display the point values, point indices, or custom string labels for each point.
PlotWindow Styling Methods
The user can change the styling of the output plot via FreeFlyer script. For example, the SeriesColorPalette, BackgroundColorPalette, LineWidth and text of the plot title and subtitle can be edited. The SeriesColorPalette is the color palette which will be used to stylize the series displayed in the specified PlotWindow. The BackgroundColorPalette is the color palette which will be used to stylize the plot displayed in the specified PlotWindow. The table below shows the options available for the PlotWindow.SetSeriesColorPalette() method.
The syntax example below displays a few of the Plot styling methods available in FreeFlyer scripting.
Hide Data from a PlotWindow
You can hide data from a PlotWindow by adding or removing data points. This can be used to display only the most important data at different times, or to color-code the data during an event. See the Sample Mission Plan PlotWindow - Scatter Series to see a complete example.
Export the PlotWindow
The data and image of the PlotWindow can be saved via FreeFlyer script. The high quality rendering option smooths the image so that the plot appears less pixelated.
Using the Assign (=) Operator
You can assign Series, Font, Title, Axis, and Legend Objects equal to other Objects of the same type using the assign (=) operator. This works differently than how the assign (=) operator works with Spacecraft or GroundStation Objects. With plot-related objects, assignment of two objects will assign the properties of all their child objects as well. For example, for a Plot Axis, its child Font and Title objects will be assigned (as well as the Font of the Title child object). See the syntax example and output below.
This lets the user easily configure multiple plots to have a consistent look and feel.
Note: A PlotSeries object can only be added to single PlotWindow. If you want to add the same PlotSeries object to a second PlotWindow object, you should use the Assign operator to create a second copy of the series.
PlotWindow Object Editor
You can also create a PlotWindow in the Object Browser.
The Content page allows users to configure the type of plot to generate (Cartesian or polar, as seen in the images below) and specify the data to show on each axis.
The Properties page of the PlotWindow object editor allows the user to configure custom titles and axis labels, using custom fonts and text styles, and set the maximum points and points to update properties. The "All Output Properties" button allows the user to edit any of the Plot Properties, as described in the section below. Users can also enable monitor mode, select whether to show lines, points, data labels, and/or grid lines.
Note: For Mission Plans still using millisecond precision mode, the Properties page also lets you define the Update Mode of the ViewWindow. As of FreeFlyer 7.3, the default timing precision mode is nanosecond precision mode; which provides more modern and robust interfaces for this functionality. See Object vs. Command Output for more information on the Update Mode and Target Display Mode.
Available from both the PlotWindow object dialog and the Output Properties tab within the workspace, the Plot Output Properties panel gives access to every property that can affect the display of the PlotWindow. All of these properties are configurable through FreeFlyer scripting as well. The following list describes the areas of the PlotWindow that can be edited by the Plot Output Properties window.
Plot Properties Panel
Note: Using the replay toolbar after the Mission Plan has completed execution will not affect the contents of a PlotWindow.
•PlotWindow Properties and Methods