Only one kernel for two data sets in scatter-histogram?

Each data set (only two) is displayed in different colors within the scatter plot and on the y-axis kernel, however the x-axis kernel only displays one data set?? I am using the code below:
figure
xA(:,2)=1;
xB(:,2)=2;
species=vertcat((xA(:,2)),(xB(:,2)));
x=vertcat((xA(:,1)),(xB(:,1)));
y=vertcat(yC(:,1),yD(:,1));
scatterhist(x,y,'Group',species,'Kernel','off','Color',[black;red],'LineStyle',{'-','-'},'Marker','.','MarkerSize',10,'Legend','off');
xlim([-2 1]);
I would appreciate any help here. Thanks

回答(0 个)

类别

帮助中心File Exchange 中查找有关 Discrete Data Plots 的更多信息

提问:

2017-9-12

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by