A few weeks after releasing my tutorial for installing Jupyter Notebook on Android, I ran into this issue of Matplotlib: TclError: no display name and $DISPLAY environment variable, whenever I tried to use it in Jupyter Notebook on Android. This problem got me puzzled for a while because I knew it used to work when I was writing the tutorial. Luckily, there is a one-line fix for this issue. So, in case you don’t have time for any other details, just put this line at the beginning of the notebook:

%matplotlib inline
Matplotlib no display ERROR on Android

Check the example, it works!

Read More