I know it's a very old topic, but I had the issue myself running:
django-nvd3==0.9.7
python-nvd3==0.14.2
If you take a look at the python-nvd3 lineChart.py (line 27) code example, you'll see the color must be passed as keyword argument like so:
kwargs2 = {'color': 'red'}
chart.add_serie(y=ydata, x=xdata, name='sine', extra=extra_serie, **kwargs1)
Then if you take a look at django_nvd3/templatetags/nvd3_tags.py#L67 source you can see the this same keyword argument is recreated from each series just like the "extra1" and "extra2" is created from their demo_linechart. So if you want to have one line red and the other one blue you can do the following:
chartdata = {
'x': xdata,
# series 1
'name1': 'series 1',
'y1': ydata,
'extra1': extra_serie1,
'kwargs1': { 'color': 'red'}, # <- the important part
# series 2
'name2': 'series 1',
'y2': ydata2,
'extra2': extra_serie2,
'kwargs2': { 'color': 'blue'}, # <- the important part
}
I'll probably create a pool request with the fix.
Edit: I've created a pull request that fixes the code example.