By Nathan Donaldson
Tags: Development
We’ve released a radar (spider, polar) chart component for Flex as an open source (MIT) project on github. This is abstracted from our Sonarhq product. For the most part we’ve been using the Flex Charting components from Adobe, but this doesn’t include radar charts. We looked at several commercial packages, but these turned out to be either too expensive, or not flexible enough. There is a free component a vailable at Kap Lap, but it didn’t support the styles we needed to match the design we had.
In the end it was easier to produce our own (about a day and a half of work). The project depends on some common libraries we’ve developed at Boost over the last couple of years, which we haven’t decided on open sourcing yet, but we have included the binary under the same license so that the charting component can work. Here’s a demo and how to get going:
Download the code or the swc [230KB] file from github and create a new project. In the project properties add the swc library or open the chart project and include it. Create an application with the following code:
This will show a simple chart similar to the one here. The charts can be styled quite a bit. Take a look through the code to see the styles that can be applied. Note that I haven’t yet allowed for styling the bits of text.
Originally my intention was to extend the flex charting objects in order to implement the chart. Unfortunately I found the structure a bit complex, and documentation for extending non-existent. I’m sure it would have been possible, but I didn’t get very far and just wanted to just get it done.
Update 24th Aug 2009: New release that fixes issues with drawing the highlight and removing series radar_chart-1.1.swc.
Update 28th Oct 2009: New release that fixes removing labels when removing axis: radar_chart-1.2.swc.
Update 16th Jul 2010: Release that works correctly with Flex 4. This is for Flex 4 (Flash Builder 4) only, and will not work with Flex 3. radar_chart-1.3-flex4.swc.