Verified Commit 610f52cc authored by Qusai Al Shidi's avatar Qusai Al Shidi 💬
Browse files

tecplot documentation fixes

parent 6de2102c
Pipeline #25937 passed with stage
in 50 seconds
...@@ -637,15 +637,21 @@ This is helpful for accessing Tecplot variables. ...@@ -637,15 +637,21 @@ This is helpful for accessing Tecplot variables.
**Examples**: **Examples**:
In a dataset which contains the variable 'X [R]', In a dataset which contains the variable 'X [R]',
```print(dataset.variable_names) ```python
>>> ['X [R]', ... ]``` print(dataset.variable_names)
# ['X [R]', ... ]
```
The following will fail: The following will fail:
```print(dataset.variable('X [R]').name) ```python
>>> TecplotPatternMatchWarning: no variables found matching: "X [R]" For print(dataset.variable('X [R]').name)
# TecplotPatternMatchWarning: no variables found matching: "X [R]" For
a literal match, the meta-characters: * ? [ ] must be wrapped in square- a literal match, the meta-characters: * ? [ ] must be wrapped in square-
brackets. For example, "[?]" matches the character "?"...``` # For example, "[?]" matches the character "?"...
```
However, However,
```print(dataset.variable(tpt.bracketify('X [R]')).name)``` ```python
print(dataset.variable(tpt.bracketify('X [R]')).name)
```
will succeed. will succeed.
<a name="swmfpy.tecplottools.write_zone"></a> <a name="swmfpy.tecplottools.write_zone"></a>
......
...@@ -271,15 +271,21 @@ def bracketify(variable_name: str) -> str: ...@@ -271,15 +271,21 @@ def bracketify(variable_name: str) -> str:
Examples: Examples:
In a dataset which contains the variable 'X [R]', In a dataset which contains the variable 'X [R]',
```print(dataset.variable_names) ```python
>>> ['X [R]', ... ]``` print(dataset.variable_names)
# ['X [R]', ... ]
```
The following will fail: The following will fail:
```print(dataset.variable('X [R]').name) ```python
>>> TecplotPatternMatchWarning: no variables found matching: "X [R]" For print(dataset.variable('X [R]').name)
# TecplotPatternMatchWarning: no variables found matching: "X [R]" For
a literal match, the meta-characters: * ? [ ] must be wrapped in square- a literal match, the meta-characters: * ? [ ] must be wrapped in square-
brackets. For example, "[?]" matches the character "?"...``` # For example, "[?]" matches the character "?"...
```
However, However,
```print(dataset.variable(tpt.bracketify('X [R]')).name)``` ```python
print(dataset.variable(tpt.bracketify('X [R]')).name)
```
will succeed. will succeed.
""" """
translation = { translation = {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment