python - Django-NVD3 - Cannot change line color -


I have many graphs on one page and I am unable to change the color of the lines, even if I am clearly this. I followed the official documents and did not change the colors. extra_series1 = {"ytstart": {"y_start": "", "y_end": "mbps"}, "datatat": tooltip_adt, 'color': '# 555555'} chartdata = '' x ': xdata,' name1 ':' requests per second ',' y1 ': ydata,' extra1 ': extra_series1}

but in additional: 'x_is_date': True, 'x_axis_format': '% H:% M:% S', 'tag_script_js': True, 'jquery_on_ready': Incorrect, 'color_category': 'Category10',

and the graph with multiple lines will have a color palette from the graph. However, I need different colors for 1 line graph.

< p>

POS T-text "itemprop =" text ">

I know this is a very old topic, but I have a problem with this problem:

  django-nvd3 == 0.9.7 Python-NVD3 = 0.14.2   

If you take a look at the code example, you will see that the color must be passed as a keyword argument such as:

  kwargs2 = {'color': 'red'} chart.add_serie (y = ydata, x = xdata, name = 'sine', extra = extra_serie, ** kwargs1)   

Then if you take a look at the source, then you can see that this is the same keyword Each series has been created from "extra1" and "extra2". So if you want to redraw a row and the other is blue, then you can do the following:

  chartdata = {'x': xdata, # series 1 'name1': 'series 1 ',' y1 ': ydata,' extra1 ': extra_serie1,' kwargs1 ': {' color ':' red '}, # & lt; - Important part # Series 2 'name2': 'series 1', 'y2': ydata2, 'extra2': extra_serie2, 'kwargs2': {'color': 'blue'}, # & lt; - Important part}   

I'll probably make a pool request OK.

EDIT: I have made one that resolves the code example.

Comments

Popular posts from this blog

Verilog Error: output or inout port "Q" must be connected to a structural net expression -

jasper reports - How to center align barcode using jasperreports and barcode4j -

c# - ASP.NET MVC - Attaching an entity of type 'MODELNAME' failed because another entity of the same type already has the same primary key value -