Réponse apportée
I want the plot the bar graph touching the y axis
Read about xlim, axis

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
i am getting error in the plot function it says array indices must be +ve int or logical value
t= 0:0.1:5; nt = length(t) ; v1 = zeros(size(t)) ; v2 = zeros(size(t)) ; v3 = zeros(size(t)) ; v1(1)=2; v2(1)=4; v3(1)=...

plus de 3 ans il y a | 1

| A accepté

Réponse apportée
Why the following code is not generating plot for W?
I remember you asking the similiar question earlier. What have you learned from the previous question? You are keep on asking sa...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
I need output this statement
a1=1:10 % generate numbers between 1 and 10 with increment of 1 a2 = 75:-1:50 ; % generate numbers between 75 and 50 with diff...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
Colour depending on the radius of a cylinder.
Try: pxI = pxS(:,:,i); pyI = pyS(:,:,i); R = sqrt(pxI.^2+pyI.^2) ; surf(pxI,pyI,pz,R);

plus de 3 ans il y a | 1

| A accepté

Réponse apportée
Assigning values from one array to string values of another array
ideanumber = ["idea1", "idea2","idea3", "idea4","idea5", "idea6","idea7", "idea8", "idea9"] ; scorevector = [5.7065, 3.2885,...

plus de 3 ans il y a | 0

Réponse apportée
How to compose more than 2images in a folder ?
imgFiles = dir('*jpg') ; N = length(imgFiles) ; I1 = imread(imgFiles(1).name) ; I2 = imread(imgFiles(2).name) ; If = imfuse(...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
how to increment an exponential in a diagonal
A = exp(-1./(1:19)) ; iwant = diag(A)

plus de 3 ans il y a | 1

Réponse apportée
For loop to save all the files
Thanks is accepting the answer.. :)

plus de 3 ans il y a | 0

Réponse apportée
Calculate difference between two columns but skip if column has NaN
You simply subtract the two columns....if any of the column has NaN, your difference will be NaN. A = [NaN 24 ...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
double surface using scatteredInterpolant
T = readtable('https://in.mathworks.com/matlabcentral/answers/uploaded_files/1065115/zoccolo.txt') ; zoccolo = table2array(T) ;...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
creating folder in matlab
Read about mkdir

plus de 3 ans il y a | 0

Réponse apportée
For loop to save all the files
for i = 1:10 plot(rand(1,10)) figName = ['plot_',num2str(i),'.png'] ; % you can give path, your desired string here ...

plus de 3 ans il y a | 1

Réponse apportée
Getting error while trying to access the data of the following plot.
You are plotting the data using fplot. This will give you the function, which you have used to plot when you try to extract the ...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
Evaluating and plotting a kernel function
% Evaluating kernal functions, kernal 2 Fs = 33600 ; n = 1:1:Fs; a = floor(n-(Fs/2)); c = (1200*pi)/Fs; % c is greek le...

plus de 3 ans il y a | 0

Réponse apportée
To find n number of histcounts in a loop
z = cell2mat(N) ; Or z = [N{:}] ;

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
I want to give a condition to the values of the x vector , i tried to dosomething but i didnt have teh results i wanted. helpp please
w = 0.1; h = 0.1; L = 8.0; E = 210.0E9; F = 3000.0; a = L/4; x = linspace(0,8,100) ; I = (w*h^3)/12;%Calculate variable I...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
Dimensions of arrays being concatenated are not consistent.
This line: TimeM = [AA(:,1) BB(:,1) CC(:,1) DD(:,1)] ; will throw error. Note that BB, CC and DD are of size 20x2 and AA(:,1)...

plus de 3 ans il y a | 0

Réponse apportée
Division of numbers and arrange??
% With loop A=[2 8 14 20 22 26 32 38 44 45] Divisible=[] ; NotDivisible=[] for index=1:length(A) b=A(index) ; if...

plus de 3 ans il y a | 0

Réponse apportée
How can i input this on MATLAB?
b = [3, 7, -4]' ; u1=[1, 2, 3]; u2 =[2, 3, 7]; u3 =[3, 5, 6] ; A = [u1' u2' u3'] ; x = A\b ; % check [A*x b]

plus de 3 ans il y a | 0

Réponse apportée
I want to use contourf function to plot 2d velocity data
Let u,v be your velcity matrices. w = sqrt(u.^2+v.^2) ; figure(1) pcolor(x,y,w) ; % if throws error, transpose w colorbar...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
How to put different seed in a multidimensional matrix
n = 10; k = 3 ; R = zeros(n,k,n) ; for i = 1:n rng(i) % i can be a positive integer R(:,:,i) = rand(n,k) ; end

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
To find histogram of two variables
x = rand(1000,1); y = rand(1500,1); [N{1},edges{1}] = histcounts(x); [N{2},edges{2}] = histcounts(y);

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
can you please give me the answers
a)Also, create an empty vector called prime_numbers Read about initializng the arrays. Hint: zeros, ones b)In the while loop,...

plus de 3 ans il y a | 0

Réponse apportée
Matlab Plot can't work.
clc clear clc f = @(x,y,z) 1/y*(y+z); %where k = 1 for y'' g = @(x,y,z) z ; %for y' h = 0.1; x= 0; z= 1; y= ...

plus de 3 ans il y a | 0

| A accepté

Réponse apportée
How can I extract data from the following Matlab figure, there are multiple lines.
Already you have them in xdata and ydata. They are cell arrays, you can access them by: xdata{1} xdata{2} ydata{1} ydata{2...

plus de 3 ans il y a | 1

Réponse apportée
Error using plot Data
clear clc %%INPUT / DATA %a = input('Value of a:') %b = input('Value of b:') %c = input('Value of c:') a=1; b=1; c=1; ...

plus de 3 ans il y a | 1

| A accepté

Réponse apportée
How to convert images folder to .mat
thepath = 'C:\Users\hp\Desktop\testing\abood' ; imgFiles = dir([thepath,'\*jpg']) ; % give your image extension N = length(im...

plus de 3 ans il y a | 0

Réponse apportée
I couldn't understand why this program is not working, is my all variable algorithm is correct?
You need to interchange the variables to the function rate_eq. Try this: ti = 0; tf = 10E-4; tspan=[ti tf]; y0=[9;9;1;1;0].*...

plus de 3 ans il y a | 0

| A accepté

Charger plus