{"action":"created","issue":{"url":"https://api.github.com/repos/openspending/os-viewer/issues/4","repository_url":"https://api.github.com/repos/openspending/os-viewer","labels_url":"https://api.github.com/repos/openspending/os-viewer/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/openspending/os-viewer/issues/4/comments","events_url":"https://api.github.com/repos/openspending/os-viewer/issues/4/events","html_url":"https://github.com/openspending/os-viewer/issues/4","id":118417215,"number":4,"title":"Views Panel: Multiple Series Visualisations (Bar, Line)","user":{"login":"pwalsh","id":791678,"avatar_url":"https://avatars.githubusercontent.com/u/791678?v=3","gravatar_id":"","url":"https://api.github.com/users/pwalsh","html_url":"https://github.com/pwalsh","followers_url":"https://api.github.com/users/pwalsh/followers","following_url":"https://api.github.com/users/pwalsh/following{/other_user}","gists_url":"https://api.github.com/users/pwalsh/gists{/gist_id}","starred_url":"https://api.github.com/users/pwalsh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwalsh/subscriptions","organizations_url":"https://api.github.com/users/pwalsh/orgs","repos_url":"https://api.github.com/users/pwalsh/repos","events_url":"https://api.github.com/users/pwalsh/events{/privacy}","received_events_url":"https://api.github.com/users/pwalsh/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/openspending/os-viewer/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"closed","locked":false,"assignee":{"login":"borysyuk","id":12050260,"avatar_url":"https://avatars.githubusercontent.com/u/12050260?v=3","gravatar_id":"","url":"https://api.github.com/users/borysyuk","html_url":"https://github.com/borysyuk","followers_url":"https://api.github.com/users/borysyuk/followers","following_url":"https://api.github.com/users/borysyuk/following{/other_user}","gists_url":"https://api.github.com/users/borysyuk/gists{/gist_id}","starred_url":"https://api.github.com/users/borysyuk/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/borysyuk/subscriptions","organizations_url":"https://api.github.com/users/borysyuk/orgs","repos_url":"https://api.github.com/users/borysyuk/repos","events_url":"https://api.github.com/users/borysyuk/events{/privacy}","received_events_url":"https://api.github.com/users/borysyuk/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/openspending/os-viewer/milestones/2","html_url":"https://github.com/openspending/os-viewer/milestones/Current","labels_url":"https://api.github.com/repos/openspending/os-viewer/milestones/2/labels","id":1425419,"number":2,"title":"Current","description":"","creator":{"login":"pwalsh","id":791678,"avatar_url":"https://avatars.githubusercontent.com/u/791678?v=3","gravatar_id":"","url":"https://api.github.com/users/pwalsh","html_url":"https://github.com/pwalsh","followers_url":"https://api.github.com/users/pwalsh/followers","following_url":"https://api.github.com/users/pwalsh/following{/other_user}","gists_url":"https://api.github.com/users/pwalsh/gists{/gist_id}","starred_url":"https://api.github.com/users/pwalsh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwalsh/subscriptions","organizations_url":"https://api.github.com/users/pwalsh/orgs","repos_url":"https://api.github.com/users/pwalsh/repos","events_url":"https://api.github.com/users/pwalsh/events{/privacy}","received_events_url":"https://api.github.com/users/pwalsh/received_events","type":"User","site_admin":false},"open_issues":0,"closed_issues":24,"state":"open","created_at":"2015-11-23T16:20:47Z","updated_at":"2016-02-24T07:37:42Z","due_on":null,"closed_at":null},"comments":0,"created_at":"2015-11-23T16:22:49Z","updated_at":"2016-02-24T07:37:42Z","closed_at":"2016-02-24T07:37:42Z","body":"# Description\r\n\r\nEssentially, we are building visualisations using D3. And, for basic visualisations, we have two broad types:\r\n\r\n* single series visualisations #3\r\n* multiple series visualisations (this)\r\n\r\nFor each type, the current state of the data will need to be further processed into the specific shape required for a given visualisation. This processed version is very specific to the particular component rendering the visualisation, and therefore we do not need to keep this further modified data presentation in our state tree. \r\n\r\nFor example, in the current Treemap, we do this [final processing in the component](https://github.com/openspending/fiscal-data-package-viewer/blob/master/src/scripts/components/views/Treemap.js#L8), using a function that produces the input a [D3 Treemap expects](https://github.com/openspending/fiscal-data-package-viewer/blob/master/src/scripts/utils/index.js#L9). \r\n\r\nWe'd need to implement a similar pattern for multiple series visualisations, such as [line charts](https://reactiva.github.io/react-d3-website/).\r\n\r\n# Tasks\r\n\r\n* [ ] Add an additional two tabs to the tabbed visualisations, one for a bar chart and one for a line chart \r\n* [ ] Write a generic `dataToMultipleSeries` function for processing the current data state to that required for such views, and implement it as part of the view component\r\n* [ ] Write tests for the component that renders each view\r\n* [ ] Write tests for the `dataToMultipleSeries` function"},"comment":{"url":"https://api.github.com/repos/openspending/os-viewer/issues/comments/188125978","html_url":"https://github.com/openspending/os-viewer/issues/4#issuecomment-188125978","issue_url":"https://api.github.com/repos/openspending/os-viewer/issues/4","id":188125978,"user":{"login":"pwalsh","id":791678,"avatar_url":"https://avatars.githubusercontent.com/u/791678?v=3","gravatar_id":"","url":"https://api.github.com/users/pwalsh","html_url":"https://github.com/pwalsh","followers_url":"https://api.github.com/users/pwalsh/followers","following_url":"https://api.github.com/users/pwalsh/following{/other_user}","gists_url":"https://api.github.com/users/pwalsh/gists{/gist_id}","starred_url":"https://api.github.com/users/pwalsh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pwalsh/subscriptions","organizations_url":"https://api.github.com/users/pwalsh/orgs","repos_url":"https://api.github.com/users/pwalsh/repos","events_url":"https://api.github.com/users/pwalsh/events{/privacy}","received_events_url":"https://api.github.com/users/pwalsh/received_events","type":"User","site_admin":false},"created_at":"2016-02-24T07:37:42Z","updated_at":"2016-02-24T07:37:42Z","body":"N/A"}}