signF {Tex4exams} | R Documentation |
The minus sign in fractions should be in front of the fraction for display purpose, while many numerical algorithms may produce fractions with minus sign in the numerator. This function modifies the output of those packages into the correct display form in TeX code.
signF(a)
a |
a numeric number. |
The function returns one of the symbols "-" for negative numbers, or empty "" for nonnegative ones.
a <- sample(c((-10):10),1)/100
signF(a)