2
MatLab中的散點圖。我可以創建x和y陣列是相同的大小,如下散點圖:MatLab:散點圖和柵格圖
function RasterTest()
clear all % clear memory
clc; % clear command window
close all; % close any figure windows that are open
x=[1 2 3]; % x positions of the charges
y=[4 8 2]; % y positions of the charges
scatter(x,y,'filled')
axis square
end
不過,如果我想每x有多個y值是什麼?即陣列大小不同。我認爲這實際上被稱爲柵格圖,但是MatLab似乎沒有這樣的功能?
任何幫助將是偉大的:)。
我最終做的就是使用'hold on'和覆蓋圖工作正常。 pccofre的答案似乎也是正確的。 – ale 2011-02-26 14:47:35