summaryrefslogtreecommitdiffstats
path: root/ds9/library/markeranalysisplot2d.tcl
diff options
context:
space:
mode:
authorWilliam Joye <wjoye@cfa.harvard.edu>2018-09-27 21:19:04 (GMT)
committerWilliam Joye <wjoye@cfa.harvard.edu>2018-09-27 21:19:04 (GMT)
commitcc5df79627b75a1fcd807ff73319e1a3d3cb2b63 (patch)
treecc9a0745bdd56072d15f0cea1b258a8fccf8daba /ds9/library/markeranalysisplot2d.tcl
parenteafc6af129cf5f2c71ee4fde54885e0167dd96e5 (diff)
downloadblt-cc5df79627b75a1fcd807ff73319e1a3d3cb2b63.zip
blt-cc5df79627b75a1fcd807ff73319e1a3d3cb2b63.tar.gz
blt-cc5df79627b75a1fcd807ff73319e1a3d3cb2b63.tar.bz2
REGION: use BUNIT keyword if available
Diffstat (limited to 'ds9/library/markeranalysisplot2d.tcl')
-rw-r--r--ds9/library/markeranalysisplot2d.tcl8
1 files changed, 6 insertions, 2 deletions
diff --git a/ds9/library/markeranalysisplot2d.tcl b/ds9/library/markeranalysisplot2d.tcl
index 121e948..a8fdf1d 100644
--- a/ds9/library/markeranalysisplot2d.tcl
+++ b/ds9/library/markeranalysisplot2d.tcl
@@ -154,7 +154,11 @@ proc MarkerAnalysisPlot2dCB {frame id} {
if {!$ping} {
set tt [string totitle [$frame get marker $id type]]
- PlotLineDialog $vvarname $tt {} $vvar(system) Counts
+ set vvar(bunit) [string trim [$frame get fits header keyword BUNIT]]
+ if {$vvar(bunit)=={}} {
+ set vvar(bunit) {Counts}
+ }
+ PlotLineDialog $vvarname $tt {} $vvar(system) $vvar(bunit)
MarkerAnalysisPlot2dXAxisTitle $vvarname
MarkerAnalysisPlot2dYAxisTitle $vvarname
@@ -240,7 +244,7 @@ proc MarkerAnalysisPlot2dYAxisTitle {vvarname} {
global $vvarname
# set for plot code
- set vvar(axis,y,title) "Counts [string totitle $vvar(method)]"
+ set vvar(axis,y,title) "$vvar(bunit) [string totitle $vvar(method)]"
# update now (may not make it into plot code)
$vvar(graph) yaxis configure -title $vvar(axis,y,title)