I've uploaded a macro to the template store that does the above. It uses Autoinput & to use it you need to create the Autoinput input commands for your phone by navigating to settings, then select Status bar, finally select internet speed (which toggles the setting) - these are all the steps you perform to toggle status bar internet speed display manually.
The Autoinput gesture is required on my phone to scroll Settings to make Status Bar visible.
The Autoinput global commands are Back - just removes Status Bar Settings screen from the display.
I would prefer to keep the internet speed display on permanently but the lack of a threshold setting below which the speed is not displayed is missing from stock Android. I use the internet infrequently and dislike the 0.00k/s speed display and found manually changing the setting was slow involving many actions - the toggle macro makes it very easy to control visibility of the status bar internet speed display.