BMs are mostly happening in the morning and at the end of the day (we’re designed that way I guess). These are not my words, but the MD’s words I visit for advices.
If you have IBS, then thats the reason actually (I presume). I also get bloating often at that time.
It’s also directly connected with the food like others advised, since if you eat problematic food its more likely that your symptoms will be stronger.