1. #1
    Ext User
    Join Date
    Sep 2010
    Posts
    26
    Vote Rating
    0
    kudos_ni_ is on a distinguished road

      0  

    Question Pie Chart data from bean list

    Pie Chart data from bean list


    Hi All,

    I have a list of object constructed from raw JSON data of the following format - the sample below shows one object:

    Code:
    "Position" : [ { 
                "AssetClass" : "Equity Securities",
                "Industry" : "Chemicals",
                "IndustryGroup" : "Materials",
                "PercentOfPortfolio" : 2.24,
                "Position" : 349399,
                "PricingDate" : "10/07/2010",
                "Sector" : "Materials",
                "SecurityName" : "MONSANTO CO",
                "SecurityType" : "EQUITIES",
                "SubIndustry" : "Fertilizers & Agricultural Chemicals",
                "Symbol" : "MON"
              }]
    I use this list to populate a grid which allows grouping.

    I want to create a pie chart which updates depending on what gouping is applied to the grid. But I am lost as to where to start.

    For example, if the data is grouped by "Sector", I would want the pie chart to illustrate each slice as a sector, with the value being the sum of "PercentOfPortfolio" for all objects in that sector. I hope that makes sense.

    I am not sure where to begin in adding this list to the chart.

    Can anybody point me in the right direction?

    Thanks.

  2. #2
    Software Architect
    Join Date
    Sep 2007
    Posts
    13,966
    Vote Rating
    130
    sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light sven is a glorious beacon of light

      0  

    Default


    You can use a PieDataProvider for this for example.

    But you can also do it manually if you want. Listen to the Store.DataChanged event (gets fired on grouping) and redo your charting.

  3. #3
    Ext User
    Join Date
    Sep 2010
    Posts
    26
    Vote Rating
    0
    kudos_ni_ is on a distinguished road

      0  

    Default


    Thanks.

    I can't seem to find any examples of the use of the PieDataProvider and the API docs are not helpful.

    Do you have any examples of implementing this?

Similar Threads

  1. pie chart data store
    By spbroom in forum Ext 3.x: Help & Discussion
    Replies: 4
    Last Post: 20 Aug 2010, 2:18 AM
  2. Pie Chart
    By Bleak in forum Ext 3.x: Help & Discussion
    Replies: 1
    Last Post: 6 Feb 2010, 10:05 PM
  3. Grid<Bean> when bean contains some list.
    By valery.stroeder in forum Ext GWT: Discussion
    Replies: 7
    Last Post: 28 Jan 2010, 4:23 AM
  4. [ext 3.0.3] Pie chart disappear wher chart store is reloaded
    By e-tip in forum Ext 3.x: Help & Discussion
    Replies: 0
    Last Post: 24 Nov 2009, 7:12 AM
  5. Pie chart not reloading
    By ruchika in forum Ext 3.x: Help & Discussion
    Replies: 1
    Last Post: 23 Jun 2009, 9:18 AM

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar