Is it somehow possible to have certain output appear in a different color in the IPython Notebook? For example, something along the lines of:
print(\"Hello
Thanks to @alvas function and adding another function we get a very simple way to print
from IPython.display import HTML as html_print
from IPython.display import display
def cstr(s, color='black'):
return "{} ".format(color, s)
def print_color(t):
display(html_print(' '.join([cstr(ti, color=ci) for ti,ci in t])))
print_color((('hello my name is', 'black'),('jhjfd','red')))
print_color((('hello my name is', 'green'),))