Page 1 of 1

how to change the energy range of interpolated energy band

Posted: Wed Apr 13, 2022 1:33 pm
by Yuan Pang
Dear developers,

I want to plot exciton weights on interpolated band structure by yambopy. Firstly, I obtained exciton weights in band structure not interpolated as shown in following figure (Fig1). Next, I abtianed exciton weights in interpolated band structure (Fig2). However, I find that the energy range of y axis in Fig2 is significantly different from the Fig1. I inspected the excitondb.py, but I still don't have an idea as to what is causing this problem, as well as how can I adjust this range. Please give me some advice.

Best regards,
Pang

Re: how to change the energy range of interpolated energy band

Posted: Wed Apr 13, 2022 2:32 pm
by amolina
Dear Pang,

In order to plot the interpolated bands I guess that you are using the function plot_ax. In this function you are passing as variable the figure object of matplotlib, usually named "ax".
You can change all the attributes of this object. For instance, for the ylim you can change by setting (after calling plot_ax function):
ax.set_ylim(-1.0,3.0)

Hope it helps.

Alejandro

Re: how to change the energy range of interpolated energy band

Posted: Thu Apr 14, 2022 8:35 am
by Yuan Pang
Dear Alejandro,

Thanks for your reply.

I found my bug. As you said, I did use the function of plat_ax. Although I changed ylim settings before asking the question, however, I forgot that it needs to work after calling plot_ax function. Thanks again for your helpful reply.

Best regards,
Pang