[chronojump] In inertial encoder analysis all sessions, round the equivalent mass, and add " Kg"



commit 12779d6dcb219c49efc37d1175aaf3c739f29284
Author: Xavier de Blas <xaviblas gmail com>
Date:   Mon Apr 11 12:35:01 2022 +0200

    In inertial encoder analysis all sessions, round the equivalent mass, and add " Kg"

 encoder/graph.R | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/encoder/graph.R b/encoder/graph.R
index 268561088..5203dbb36 100644
--- a/encoder/graph.R
+++ b/encoder/graph.R
@@ -2285,7 +2285,11 @@ paintCrossVariables <- function (paf, varX, varY, option,
                 
                 #difficult to create a title in series graphs
                 title(paste(varXut,"/",varYut), cex.main=1, font.main=2)
-                
+
+               #on equivalent mass, series are numbers, round it and add Kg
+               if(inertialGraphX == "EQUIVALENT_MASS" && is.numeric(seriesName))
+                       seriesName = paste(round(seriesName,2), "Kg")
+
                 #plot legend on top exactly out
                 #http://stackoverflow.com/a/7322792
                 rng=par("usr")


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]