diff options
| author | shivesh <s.p.mandalia@qmul.ac.uk> | 2019-04-24 14:01:44 +0100 |
|---|---|---|
| committer | shivesh <s.p.mandalia@qmul.ac.uk> | 2019-04-24 14:01:44 +0100 |
| commit | ff83600b0ac2f2ed9f0270b905313ea42c90e3f3 (patch) | |
| tree | 73fb297e240ec574fb791bf50dd5982d22a49d25 /utils | |
| parent | ad550dc259167f7d62593b024be7fa2a1c7cb75a (diff) | |
| parent | 465dfedfe5752b4e2f8b07606056f72d71911c43 (diff) | |
| download | GolemFlavor-ff83600b0ac2f2ed9f0270b905313ea42c90e3f3.tar.gz GolemFlavor-ff83600b0ac2f2ed9f0270b905313ea42c90e3f3.zip | |
Merge branch 'refactor' of github.com:ShiveshM/flavour_ratio into refactor
Diffstat (limited to 'utils')
| -rw-r--r-- | utils/plot.py | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/utils/plot.py b/utils/plot.py index 9fd2f52..7edea6e 100644 --- a/utils/plot.py +++ b/utils/plot.py @@ -78,13 +78,15 @@ if 'submitter' in socket.gethostname(): def gen_figtext(args): """Generate the figure text.""" - t = '' - t += 'Source flavour ratio = [{0}]'.format(solve_ratio(args.source_ratio)) + t = r'$' + t += r'{\rm Source\:flavour\:ratio}'+r'\:=\:({0})'.format( + solve_ratio(args.source_ratio).replace('_', ':') + ) if args.data in [DataType.ASIMOV, DataType.REALISATION]: - t += '\nIC injected flavour ratio = [{0}]'.format( - solve_ratio(args.injected_ratio) + t += '\n' + r'\rm{Injected\:flavour\:ratio}'+r'\:=\:({0})'.format( + solve_ratio(args.injected_ratio).replace('_', ':') ) - t += '\nDimension = {0}'.format(args.dimension) + t += '$\n' + r'${\rm Dimension}'+r' = {0}$'.format(args.dimension) return t @@ -444,7 +446,8 @@ def plot_statistic(data, outfile, outformat, args, scale_param, label=None): fig = plt.figure(figsize=(7, 5)) ax = fig.add_subplot(111) - ax.set_xlim(np.log10(args.scale_region)) + xlims = SCALE_BOUNDARIES[args.dimension] + ax.set_xlim(xlims) ax.set_xlabel(r'${\mathrm {log}}_{10} \left (\Lambda^{-1}' + \ get_units(args.dimension) +r'\right )$', fontsize=16) if args.stat_method is StatCateg.BAYESIAN: |
