Code Monkey home page Code Monkey logo

Comments (4)

CapAllen avatar CapAllen commented on June 23, 2024

It's because of the different version of PyEcharts.
You can change the code from example.commons import Faker in help_funcs.py to from pyecharts.faker import Faker.

from dashboard.

hehichens avatar hehichens commented on June 23, 2024

i changed it, but i got another error.

Traceback (most recent call last):
  File "run.py", line 36, in <module>
    count_user_D_graph = line_counter(df)
  File "/home/hichens/GitProject/Dashboard/help_funcs.py", line 109, in line_counter
    series = df.set_index('date_joined').resample(freq).apply(count_users).cumsum()
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/resample.py", line 285, in aggregate
    result = self._groupby_and_aggregate(how, grouper, *args, **kwargs)
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/resample.py", line 359, in _groupby_and_aggregate
    result = grouped._aggregate_item_by_item(how, *args, **kwargs)
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/groupby/generic.py", line 1162, in _aggregate_item_by_item
    result[item] = colg.aggregate(func, *args, **kwargs)
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/groupby/generic.py", line 265, in aggregate
    return self._python_agg_general(func, *args, **kwargs)
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/groupby/groupby.py", line 927, in _python_agg_general
    result, counts = self.grouper.agg_series(obj, f)
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/groupby/ops.py", line 863, in agg_series
    return grouper.get_result()
  File "pandas/_libs/reduction.pyx", line 284, in pandas._libs.reduction.SeriesBinGrouper.get_result
  File "pandas/_libs/reduction.pyx", line 195, in pandas._libs.reduction._BaseGrouper._apply_to_group
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/groupby/groupby.py", line 914, in <lambda>
    f = lambda x: func(x, *args, **kwargs)
  File "/home/hichens/GitProject/Dashboard/help_funcs.py", line 93, in count_users
    subscribers = df.query('is_filled==1').shape[0]
  File "/home/hichens/anaconda3/lib/python3.7/site-packages/pandas/core/generic.py", line 5274, in __getattr__
    return object.__getattribute__(self, name)
AttributeError: 'Series' object has no attribute 'query'

from dashboard.

Jiannan28 avatar Jiannan28 commented on June 23, 2024

Same error here. Can we get the requirements.txt for different pacakge version?

from dashboard.

lvjiuluan avatar lvjiuluan commented on June 23, 2024

请问pyecharts的版本是?

from dashboard.

Related Issues (3)

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.