Code covered by the BSD License  

Highlights from
Binned Scatter Plot

5.0

5.0 | 1 rating Rate this file 24 Downloads (last 30 days) File Size: 3.71 KB File ID: #19506
image thumbnail

Binned Scatter Plot

by

 

08 Apr 2008 (Updated )

plot quantiles of y given quantiles of x.

| Watch this File

File Information
Description

With the default settings, BINNED_PLOT(X,Y) splits vector X into bins of approximately equal size, and plots each median against the median of the corresponding Y-values, as well as their inter-quartile range. X and Y must have the same number of rows or columns.

This is useful to visualize two-dimensional distributions.

Options include e.g.: plotting different quantiles; means/variances instead of quantiles; varying the number of bins; and density-dependent coloring.

Example:
  x=0:0.1:20;
  y=[sin(x); cos(x)] +randn(2,201);
  binned_plot(x,y)

Acknowledgements

This file inspired Clickfit Oh For Curve Fitting By Eye/Hand.

MATLAB release MATLAB 7.4 (R2007a)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (2)
05 Dec 2014 fateh

how could i run this code...

19 Jun 2014 MiauMiau  
Updates
12 Jan 2010

- Bug fixes: rare cases of empty bins; show minimum and maximum x-value
- New options: density-based transparency; mean/std instead of quantiles (useful for quantized data)
- Optional arguments specified as attribute/value pairs

Contact us