pylab_ml.common.common.color
- color(n, s)[source]
Color a string for terminal output.
- Parameters:
n (The name of the color or style to apply to the string.)
s (The string to color.)
"red" (eg. n =)
string" (s = "This is a red)
- Returns:
value (The input string s wrapped in terminal color codes corresponding to the color or style n.)
If n is not a valid color or style, the original string s is returned without modification.