>I also think income inequality might lead to more loneliness.
I'd say poverty just amplifies the feeling of loneliness. Japan has the same problem of loneliness [0] and they have a pretty good Gini coefficient compared to the rest of the OECD.[1]
[0] https://www.nytimes.com/2017/11/30/world/asia/japan-lonely-d...
[1] https://en.wikipedia.org/wiki/List_of_countries_by_income_eq...