All Projects → alejandro-isaza → PlotKit

alejandro-isaza / PlotKit

Licence: MIT license
OS X plotting framework

Programming Languages

swift
15916 projects
objective c
16641 projects - #2 most used programming language
ruby
36898 projects - #4 most used programming language

Projects that are alternatives of or similar to PlotKit

Plotsquared
PlotSquared - Reinventing the plotworld
Stars: ✭ 284 (+373.33%)
Mutual labels:  plots
Forge
High Performance Visualization
Stars: ✭ 140 (+133.33%)
Mutual labels:  plots
Ktikz
KtikZ provides a nice user interface for making pictures using TikZ.
Stars: ✭ 233 (+288.33%)
Mutual labels:  plots
Clip
Create charts from the command line
Stars: ✭ 5,111 (+8418.33%)
Mutual labels:  plots
Ggnet
GG.Net Data Visualization
Stars: ✭ 45 (-25%)
Mutual labels:  plots
Matplotplusplus
Matplot++: A C++ Graphics Library for Data Visualization 📊🗾
Stars: ✭ 2,433 (+3955%)
Mutual labels:  plots
Plottable
📊 A library of modular chart components built on D3
Stars: ✭ 2,834 (+4623.33%)
Mutual labels:  plots
JPlotter
OpenGL based 2D Plotting Library for Java using AWT and LWJGL
Stars: ✭ 36 (-40%)
Mutual labels:  plots
How To Mine Newsfeed Data And Extract Interactive Insights In Python
A practical guide to topic mining and interactive visualizations
Stars: ✭ 61 (+1.67%)
Mutual labels:  plots
Ggcharts
Get You to Your Desired Plot Faster
Stars: ✭ 205 (+241.67%)
Mutual labels:  plots
Unicodeplots.jl
Unicode-based scientific plotting for working in the terminal
Stars: ✭ 724 (+1106.67%)
Mutual labels:  plots
Statsviz
🚀 Instant live visualization of your Go application runtime statistics (GC, MemStats, etc.) in the browser
Stars: ✭ 1,015 (+1591.67%)
Mutual labels:  plots
Volbx
Graphical tool for data manipulation written in C++/Qt
Stars: ✭ 187 (+211.67%)
Mutual labels:  plots
Swiftplot
Swift library for Data Visualization 📊
Stars: ✭ 319 (+431.67%)
Mutual labels:  plots
Bokeh
Interactive Data Visualization in the browser, from Python
Stars: ✭ 15,822 (+26270%)
Mutual labels:  plots
Chartify
Python library that makes it easy for data scientists to create charts.
Stars: ✭ 3,054 (+4990%)
Mutual labels:  plots
Gral
Free Java library for displaying plots
Stars: ✭ 153 (+155%)
Mutual labels:  plots
COVIDvu
Volunteers building and sharing current, accurate, near real-time COVID-19 tracking and prediction tools.
Stars: ✭ 15 (-75%)
Mutual labels:  plots
otvPlots
ovtPlots: An R Package for Variable Level Monitoring
Stars: ✭ 13 (-78.33%)
Mutual labels:  plots
Swiftcharts
Easy to use and highly customizable charts library for iOS
Stars: ✭ 2,336 (+3793.33%)
Mutual labels:  plots

PlotKit

CocoaPods Compatible Carthage Compatible

Plots made easy.

PlotKit Plot

Features

  • 2D line and scatter plots
  • Multiple axes
  • Custom tick marks

Usage

To start using PlotKit quickly use the plotPoints helper function. It takes a list of points and returns a view that you can use in your app:

import PlotKit

// Generate some data to plot
let count = 1024
let t = (0..<count).map({ 2*M_PI * Double($0) / Double(count-1) })
let y = t.map({ sin($0) })

// Create a PlotView
let plotView1 = plotPoints((0..<count).map{ Point(x: t[$0], y: y[$0]) }, hTicks: .fit(6), vTicks: .fit(4))

Multiple point sets

You can have multiple curves or scatter plots in the same PlotView.

let plotView = PlotView()

let pointSet1 = PointSet(values: values1)
pointSet1.pointType = .disk(radius: 2)
pointSet2.pointColor = .red
pointSet1.lineColor = nil
plotView.addPointSet(pointSet1)

let pointSet2 = PointSet(values: values2)
pointSet2.pointType = .none
pointSet2.lineColor = .blue
plotView.addPointSet(pointSet2)

Axes

You can customize your plot axes. You can have as many axis lines as you want on the same plot.

let plotView = PlotView()

var xaxis = Axis(orientation: .horizontal, ticks: .fit(5))
xaxis.position = .value(0) 
xaxis.color = .blue
xaxis.labelAttributes = [NSForegroundColorAttributeName: NSColor.blue]
plotView.addAxis(xaxis)

var yaxis = Axis(orientation: .vertical, ticks: .distance(1))
yaxis.lineWidth = 2
plotView.addAxis(yaxis)

You can specify ticks in one of three ways:

  • fit(n): Say how many tick marks you want. PlotKit will space them evenly.
  • distance(d): Say how far appart to place tick marks.
  • list(l): Specify exactly the tick marks you want. This is the most flexible. You get to decide where to put the tick marks and also what their labels, line length and line thickness are.

Using PlotKit with Storyboards

If you want to use a PlotView in a Storyboard add an NSView and then change the class name and module like so


License

PlotKit is available under the MIT license. See the LICENSE file for more info.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].