MATLAB QUESTIONS & EXPERT ANSWERS

Ask an expert. Trust the answer.
Your academic and career questions answered by verified experts.

Illustration
How to make colorbar work for a scatter3 plot?
Zahra Moussavi - 2023-03-22

Hi,   I am plotting a set of scatter points using the below code. It works perfectly and the graph is correct. But the colorbar is just showing value...

How to plot the surface of an arbitrary given TABLE (not matrix) with X,Y,Z values?
Emerson De Souza - 2023-03-22

I want to plot the surface Z of arbitrary given values for each X,Y-pair.   I usually IMPORT the tables with the X,Y,Z data, so I they are not a matr...

i need the nodes to move in different direction
rehman bin omer Abdul - 2023-03-21

clear all; X=200; Y=200; Num=10; n=10; Loc_Nodes=zeros(2,Num); for i=1:2 x0=rand(1,Num)*X; y0=rand(1,Num)*Y; Loc_Nodes(1,:)=x0; Loc_Nodes(2,:)=y0; end...

How do I code for this random situation?
NAA - 2023-03-20

On a r*c size grid, 55% of the sites are randomly filled with X, 2% randomly filled with Y, and the rest are empty.  ...

How to smooth rough edges along a binary image
Caolan Furey - 2023-03-20

Hey, I'm trying to mark out the tips and bases of each finger on the following image I binarized the image using the following piece of code     a =...

How to augment a vector into another vector?
Muhammad Sardar Khan - 2023-03-20

v1 = [0 1 2 3], v2 = [0 1 2] the resultant v3 =[0 0; 1 0; 2 0; 3 0; 0 1; 1 1; 2 1; 3 1; 0 2; 1 2; 2 2; 3 2]  ...

Why the 2nd code does not behave like the 1st code?
Sadiq Akbar - 2023-03-20

the code of "myfunAskMathworks.m", yo and ye both are of the order 36x1 and these are correct. But in the other  code "codeWithArrays.m", it gives er...

Is it possible to vectorize for only one input?
sykim14 - 2023-03-18

Suppose there are two variables.   v1 = [1 2 3]; m1 = [1 2 3; 4 5 6]; I hope to create another matrix m2, having the same size with m1, and its (i, j...

match time stamps index
michael scheinfeild - 2023-03-18

hi i have two vectors diffrent lengths with diffrent values i want to match closest index in one vector to other   example :   v1 = [1610759986514 1...

Fastest way to find closest value in a vector
Patrik Ek - 2023-03-18

Hi,   I have a serious issue in matlab. I have 2 vectors v1 and v2 and length(v1) = 1376872, length(v2) = 1350228. Vector v2 contains information abo...

Get a Free Consultation or a Sample Assignment Review!