Scatter plot of two matrix of same size
17 views (last 30 days)
Show older comments
I have two matrix of same size (293 X 293 matrix) and i want to plot the scatter plot of these data as one matrix on X axis and one matrix on Y axix. but the matlab showing the error.
>> y=readmatrix('chr8norm_Nmin_matrix.txt');
>> x=readmatrix('chr8_spatial_distance_0.5_matrix_test.txt');
>> scatter(x,y)
Error using scatter (line 78)
X and Y must be vectors of the same length.
please help me out to solve this problem
0 Comments
Answers (1)
David Hill
on 5 Jun 2020
scatter(x(:),y(:));%after reading x and y in, make sure the matrix size is the same and of type double
0 Comments
See Also
Categories
Find more on Scatter Plots in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!