starslow.blogg.se

Tecplot 360 set values to percentages
Tecplot 360 set values to percentages












Legend ) def text_color ( self ): """`Color`: Color of legend text. Example usage:: > from nstant import PlotType, AnchorAlignment > legend = ot(PlotType.Cartesian3D).contour(0).legend > legend.anchor_alignment = AnchorAlignment.BottomCenter """. Legend ) def anchor_alignment ( self ): """`AnchorAlignment`: Anchor location of the legend. Example usage:: > from nstant import PlotType > legend = ot(PlotType.Cartesian3D).contour(0).legend > legend.show = True """. Legend ) def show ( self ): """`bool`: Show or hide the legend. figure:: /_static/images/legend_contour.png :width: 300px :figwidth: 300px """ def _init_ ( self, contour, * svargs ): self. code-block:: python :emphasize-lines: 21-36 import os import numpy as np import tecplot from nstant import * # By loading a layout many style and view properties are set up already examples_dir = _examples_directory() datafile = os.path.join(examples_dir, 'SimpleData', 'RainierElevation.lay') tecplot.load_layout(datafile) frame = tecplot.active_frame() plot = ot() # Rename the elevation variable ('E').name = "Elevation (m)" # Set the levels to nice values ntour(0).levels.reset_levels(np.linspace(200,4400,22)) legend = ntour(0).legend legend.show = True legend.vertical = False # Horizontal to_resize = False legend.label_step = 5 legend.overlay_bar_grid = False legend.position = (55, 94) # Frame percentages _type = TextBox.None_ # Remove Text box legend.header_font.typeface = 'Courier' legend.header_font.bold = True legend.number_font.typeface = 'Courier' legend.number_font.bold = True _png('legend_contour.png', 600, supersample=3). The contour legend can be positioned anywhere inside the frame using the `position` attribute of this class. This class allows you to customize the appearance of the contour legend. TabularLegend ): """Contour legend attributes. setter def custom_text ( self, value ): self. versionadded:: 2021.2 The ability to specify custom contour legend header text requires Tecplot 360 2021 R2 or later. Example usage:: > from nstant import PlotType > plot = ot(PlotType.Cartesian3D) > header = ntour(0).legend.header > e_custom_text = True > header.custom_text = 'time: &(SOLUTIONTIME) ms' See also: `e_custom_text`. The text may contain Dynamic Text and formatting tags (see User Manual). If the `use_custom_text` property is set to `True`, the legend header will contain this text instead of the name of the variable assigned to the contour group. USECUSTOMTEXT ) def custom_text ( self ): """ `str`: A string to be used in the contour legend header. setter def use_custom_text ( self, value ): self. Example usage:: > from nstant import PlotType > plot = ot(PlotType.Cartesian3D) > header = ntour(0).legend.header > e_custom_text = True > header.custom_text = 'Solution time: &(SOLUTIONTIME) ms' See also: `LegendHeader.custom_text`. If set to `True`, the legend header will be set by the `custom_text` property instead of the variable name assigned to the contour group.

tecplot 360 set values to percentages

TEXTSHAPE ) def use_custom_text ( self ): """ `bool`: Use custom text on the contour legend header. Example usage:: > from nstant import PlotType > legend = ot(PlotType.Cartesian3D).contour(0).legend > = True """ return text. note:: The font `size_units ` property may only be set to `Units.Frame` or `Units.Point`. SHOW ) def font ( self ): """`text.Font`: Font used to display the legend header. Example usage:: > from nstant import PlotType > plot = ot(PlotType.Cartesian3D) > legend_header = ntour(0).legend.header > legend_header.show = True """ return self.

tecplot 360 set values to percentages tecplot 360 set values to percentages

note:: The header text will display the name of the variable assigned to the contour group or a custom text if the `use_custom_text` is set to True. _kw ) def show ( self ): """`bool`: Show or hide the contour legend header. Style ): """ """ def _init_ ( self, legend, * svargs ): self.














Tecplot 360 set values to percentages