This is much easier to do in your SQL or whatever server-side method you
have of getting the data. I would suggest exhausting all possibilities
there before trying to muck around with the values of object properties
in your arraycollection.

-matt  

> -----Original Message-----
> From: [email protected] 
> [mailto:[EMAIL PROTECTED] On Behalf Of jovialrandor
> Sent: Wednesday, September 19, 2007 11:35 AM
> To: [email protected]
> Subject: [flexcoders] How do i aggregate data into charts
> 
> I am have data that does not have a uniqui field and 
> therefore I need to aggregate the values.
> 
> eg.
> 
> {Month: "Feb", Profit: 1200, Expenses: 400, Amount: 57}
> {Month: "Mar", Profit: 1000, Expenses: 200, Amount: 32}
> {Month: "Apr", Profit: 2000, Expenses: 600, Amount: 20}
> {Month: "Apr", Profit: 200, Expenses: 100, Amount: 80}
> 
> I want to agregate the 'Apr' data to show aggregated data in 
> the chart.
> 
> Adding both Aprils will get me the following:
> 
> {Month: "Apr", Profit: 2200, Expenses: 700, Amount: 100}
> 
> Is there an automatic way to tell Flex to aggregate the data?
> 
> Thanks
> 
> 
> 
>  
> 

Reply via email to