Giter VIP home page Giter VIP logo

biplots.jl's Introduction

Biplots.jl

Build Status

Biplot recipes in 2D and 3D for Makie.jl.

Installation

Get the latest stable release with Julia's package manager:

] add Biplots

Usage

using Biplots
using GLMakie

# data matrix (22 paintings x 6 colors)
data = [
  0.125 0.243 0.153 0.031 0.181 0.266
  0.143 0.224 0.111 0.051 0.159 0.313
  0.147 0.231 0.058 0.129 0.133 0.303
  0.164 0.209 0.120 0.047 0.178 0.282
  0.197 0.151 0.132 0.033 0.188 0.299
  0.157 0.256 0.072 0.116 0.153 0.246
  0.153 0.232 0.101 0.062 0.170 0.282
  0.115 0.249 0.176 0.025 0.176 0.259
  0.178 0.167 0.048 0.143 0.118 0.347
  0.164 0.183 0.158 0.027 0.186 0.281
  0.175 0.211 0.070 0.104 0.157 0.283
  0.168 0.192 0.120 0.044 0.171 0.305
  0.155 0.251 0.091 0.085 0.161 0.257
  0.126 0.273 0.045 0.156 0.131 0.269
  0.199 0.170 0.080 0.076 0.158 0.318
  0.163 0.196 0.107 0.054 0.144 0.335
  0.136 0.185 0.162 0.020 0.193 0.304
  0.184 0.152 0.110 0.039 0.165 0.350
  0.169 0.207 0.111 0.057 0.156 0.300
  0.146 0.240 0.141 0.038 0.184 0.250
  0.200 0.172 0.059 0.120 0.136 0.313
  0.135 0.225 0.217 0.019 0.187 0.217
]

# variable names
names = [:Black,:White,:Blue,:Red,:Yellow,:Other]

# choose any Tables.jl table
table = (; zip(names, eachcol(data))...)

# 2D relative variation biplot with colored dots
fig, ax = biplot(table, kind = :rform, dotcolor = table.Red)
ax.aspect = DataAspect()

biplot2D

Please check the docstring ?biplot for available attributes.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.