Skip to content

Commit 645147f

Browse files
committed
Tweaking plot aesthetics
1 parent dc7d968 commit 645147f

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed
-12.8 KB
Loading

tutorials/tutorial_6/plot_bands.py

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
from koopmans.io import read
21
import matplotlib.pyplot as plt
32

3+
from koopmans.io import read
4+
45
# Load the workflow
56
wf = read('cri3.kwf')
67

@@ -11,13 +12,11 @@
1112
ki_bs = ui_calc.results['band structure']
1213
ki_bs_shifted = ki_bs.subtract_reference()
1314

14-
1515
# Plot the two band structures
16-
ax = ki_bs_shifted.plot(spin=0, label='KI@LDA-up', color='tab:red', ls="-")
17-
ax = ki_bs_shifted.plot(ax=ax, spin=1, label='KI@LDA-down', color='tab:red', ls="--")
16+
ax = ki_bs_shifted.plot(spin=0, label='spin up', color='tab:red', ls="-")
17+
ax = ki_bs_shifted.plot(ax=ax, spin=1, label='spin down', color='tab:blue', ls="-")
1818

1919
ax.legend(loc='lower right', ncol=2, bbox_to_anchor=(1, 1))
2020
ax.set_ylim([-5, 5])
2121

2222
plt.savefig('cri3_bandstructures.png')
23-

0 commit comments

Comments
 (0)