MatLab (presented data) -


i have imported data matlab file contains these variables:

x 1x25 double vector  = 100  b = 62.3000  y 50x25 matrix 

i want present data on scatter plot.

you can pass vector first input plot , matrix (with dimension matches size of first vector) second input , create plot each pairing of first vector , each row/column of second input.

plot(x, y, 'o') 

enter image description here

this automatically color each row of y differently. if you'd entire plot same color, can specify color when creating plot

plot(x, y, 'o', 'color', 'black') 

enter image description here

if, however, want use scatter, you'll need make sure 2 inputs have same size. can applying repmat x make same size y

xx = repmat(x, size(y, 1), 1); scatter(xx(:), y(:))  

enter image description here


Comments

Popular posts from this blog

javascript - Clear button on addentry page doesn't work -

c# - Selenium Authentication Popup preventing driver close or quit -

tensorflow when input_data MNIST_data , zlib.error: Error -3 while decompressing: invalid block type -