Data visualisation is an integral part of reporting and analytics apps.Data visualisation is a vast field ranging from simple Bar Charts to complex interactive 3D Hyper Graphs and Web Spheres.This article presents my findings on the current state of libraries and frameworks available on iOS.
Making Data visualisation can be as easy as calling a function with the data, to coding on Graphics level drawing with primitives such as points and lines. This article categorizes libraries on the level of abstraction they provide.
- Data Visualisation Libraries
- Visualisation Libraries
- Graphics Libraries
WebView Performance Issues and Recent Development
Hybrid apps have long been associated with performance issues.On iOS, UIWebView doesn’t has access to the safari Nito JIT optimisations. Which in turns make all Web Based hybrid apps slow.
Good News for Hybrid app developers
iOS 8 supports WkWebView which now has access to this optimisation ,this optimisation can be leveraged just by shifting to this new API
Data Visualisation Libraries
Basic Plotting Libraries
- CorePlot(Cocoa touch) – Basic Barebones plotting library
- Limited 2d visualizations.
Marketed as Data UX solution, iOS Controls provides –
Apart from the basic visualisation constructs widgets are add ons which can be included for fast prototyping. Projects can be developed in Objective-C, Xcode and Xamarin.
iOS Controls is a Enterprise software, with a one time license purchase per dev.
ChartFx is a widely cross-platform enterprise tool used for desktop data visualization. It also boasts of Web support but lacks the kind of variety which D3 or Chart js Provides.
- Provides Basic Construct like Charts and grids.
- Supports Visualisations on mapping.
- Scientific data.
NChart3D is also a enterprise solution and provides similar functionality like ChartFx.
NOTE: Recently in IOS 8 UIWebView performance has increased almost two folds.
D3 (Awesome Data Visualisation Library)
D3 combines powerful data visualisation components and Data-Driven approach approach to DOM Manipulation. D3 gives very convenient chaining construct and functional style allows modular development. This approach lead to a wide array of community developed modules which can be reused and extended. THe constructs provided by D3 allow for fast prototyping without loosing flexibility of creating custom visualisation unlike other dedicated charting libraries.
- Data Binding to DOM
- Vast Community
- Provides – canvas, svg, CSS3D and WebGL renderers.
D3 has also been used with three.js to create interactive 3D visualisation running on WebGL.
Charting Library uses canvas element to build interactive designs.Charts are responsive and works on mobile devices painlessly.Charting takes relatively takes less code than D3 but is compensated with lost flexibility.
- Easy to use charting library
- Focus on Performance
- Claims to work at 100K data Points
- iOS Wrapper also available
Visualisation Library (Creative Coding Libraries)
Creative coding is a type of computer programming in which the goal is to create something expressive instead of something functional.A number of libraries have been created that aid in the rapid prototyping and development of these works.
openFrameworks is an open source C++ toolkit for creative coding. openFrameworks main difference from Processing is that it is written in C++, instead of Java.openFrameworks supports all major platforms linux, windows and OSx and on mobile android and iOS. Programmer can also embed glut code for higher degree of control.
- Allows range of useful primitives
- With a Physics engine can create awesome visualisations Dummy Game
- Native iOS code integrates with Xcode
- Touch controls
- Minko Engine is a free cross platform and open source real-time 3D framework created by Aerys.Minko is similar to unity but better. For web it function totally on HTML5 so no need of installing a plugin like unity. Also it boasts of 3D compression for faster streaming on web and mobile.
- Sprite Kit render 2D Images native code, Scene kit renders 3D graphics
- Box2d can be used to create interesting games and visualisations
- Built on top of OpenGL
- renderperfgl- WebGL
- IPad (iOS 7)- 3147 objects -25FPS
- Got 5092 objects – 30FPS
- OSx – 13546 objects – 30FPS
- sbperftest – Canvas 2D
- IPad (iOS 7)
- Score =33
- Again iOS 8 Score = 59
- Score = 70