Code Monkey home page Code Monkey logo

Comments (6)

samesense avatar samesense commented on August 16, 2024

I got this error too. You have to fix the view and the template. You can reference the piechart example to see how this is done.

In the view, you need to add extra data like in the piechart.
data = {
'charttype': charttype,
'chartdata': chartdata,
'extra': {'x_is_date': True,
'x_axis_format': "%d %b %Y %H"},
}

Then you fix the template to make it look like the piechart example.
Change
{% load_chart charttype chartdata "linechart_container" True "%d %b %Y %H" %}
to
{% load_chart charttype chartdata "linechart_container" extra %}

Now extra is iterated over, passing in x_is_date and x_axis_format.

from django-nvd3.

prasadmc avatar prasadmc commented on August 16, 2024

@samesense Thanks for the comment. I got that error resolved.

However, I have a different error now :(
error
I tried copying the files to "mysite\polls\static" folder... but, even that didn't work.
PS: I have copied all STATIC related variables from settings.py from the example

Pls help...

from django-nvd3.

samesense avatar samesense commented on August 16, 2024

@prasadmc I had this issue too. In settings.py, you need to add bower apps for d3 and nv.d3. Then run manage.py collectstatic to populate static w/ d3 and nv.d3 files. My bower app section of settings looks like this:

BOWER_INSTALLED_APPS = (
'jquery#1.9',
'underscore',
'd3#3.3.6',
'nvd3#1.1.12-beta',
)

from django-nvd3.

saposki avatar saposki commented on August 16, 2024

I am using python 2.7, django 1.9, installed django-nvd3 using "pip install django-nvd3" and followed all the instructions and i am still getting this error.

please help....

from django-nvd3.

BjoernLaemmerzahl avatar BjoernLaemmerzahl commented on August 16, 2024

I have the same problem here. StackedAreaChart however seems to work fine.

from django-nvd3.

bossajie avatar bossajie commented on August 16, 2024

how you solved this guys?

from django-nvd3.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.