matlab画矩形问题
初学matlab,还不太清楚,现在想画出一个左上角红色,右上角蓝色,左下角绿色,右下角白色的矩形,请问应该怎么做呀,谢谢! matlab
[解决办法]
rectangle('position',[0,1,1,1],'facecolor','r');
hold on;
rectangle('position',[1,1,1,1],'facecolor','b');
hold on;
rectangle('position',[0,0,1,1],'facecolor','g');
hold on;
rectangle('position',[1,0,1,1],'facecolor','w');