I need to round values in a legend in a dynamic way. This should be compatible with a latex interpreter (the r before the actual text)
I'm trying to find a way to round these variables in a dynamic way.
Thanks
Edit: the answer is in: How do I format a number with a variable number of digits in Python?