This question shows how one might print multi-line strings with indents, but it doesn't work for pandas outputs.
Take the following example:
d = pd.DataFrame(dict(x = list(range(10)), y = list(range(10))))
print(f"\t{d}")
yields:
x y
0 0 0
1 1 1
2 2 2
3 3 3
4 4 4
5 5 5
6 6 6
7 7 7
8 8 8
9 9 9
I want it to indent the whole table, not just the first two lines. Is there an easy way to do this without complicated parsing?