Search All of the Math Forum:
Views expressed in these public forums are not endorsed by
Drexel University or The Math Forum.
|
|
|
|
Re: histogram with third dimension
Posted:
Jan 22, 2013 4:17 PM
|
|
"Benjamin" wrote in message <kdm2mb$hju$1@newscl01ah.mathworks.com>... > Hi, > > with the scatter3-plot, you can plot a 2 vector scatterplot where a third vector gives you the colour of each data point. > How can i do that with a histogram? At the end of the day, i want to have a histogram where the x-axis are my values, the y-axis are the counts and i need another dimension and would like to add it similar to scatter3 with colours. So each bar would consist of stripes with colours refering to another vector of the same length of my data. > > Is this possible?
It's probably easiest to do this using the surf function. Use histc to calculate the y values, and then use surf to plot striped bars. Just set the z values of the surf to some constant value.
|
|
|
|