aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Garlick <pgarlick@tourbillion-technology.com>2022-02-10 16:56:40 +0000
committerPaul Garlick <pgarlick@tourbillion-technology.com>2022-02-10 16:56:40 +0000
commit53cac2311081d837ce2e8838b83118b8a6ddc0ad (patch)
treefee3cd2d1d57f8d024bfc4120be76a3dc0caa390
parentb7b5a707e931c54d0da62e1006ee6c3f244b1a32 (diff)
downloadfullSWOF-utils-53cac2311081d837ce2e8838b83118b8a6ddc0ad.tar.gz
boundary_profile.py: Add plot title.
* fullswof-utils/boundary_profile.py: Add title.
-rwxr-xr-xfullswof-utils/boundary_profile.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/fullswof-utils/boundary_profile.py b/fullswof-utils/boundary_profile.py
index 50b2654..8dee839 100755
--- a/fullswof-utils/boundary_profile.py
+++ b/fullswof-utils/boundary_profile.py
@@ -15,15 +15,19 @@ args = parser.parse_args()
if args.location == 'top':
inputFilename = "top_boundary.xyz"
lineColour = "tab:blue"
+ plotTitle = 'Top boundary profile'
elif args.location == 'bottom':
inputFilename = "bottom_boundary.xyz"
lineColour = "tab:green"
+ plotTitle = 'Bottom boundary profile'
elif args.location == 'left':
inputFilename = "left_boundary.xyz"
lineColour = "tab:red"
+ plotTitle = 'Left boundary profile'
elif args.location == 'right':
inputFilename = "right_boundary.xyz"
lineColour = "tab:orange"
+ plotTitle = 'Right boundary profile'
def detach_display():
x, y, z = np.loadtxt(inputFilename, delimiter=' ', unpack=True)
@@ -31,6 +35,7 @@ def detach_display():
plt.plot(x,z, color=lineColour, label='elevation')
plt.xlabel('x / m')
plt.ylabel('z / m')
+ plt.title(plotTitle)
ax.yaxis.set_minor_locator(MultipleLocator(0.2))
plt.grid(True, which='minor')
plt.show()