Answered
Saving output results in a for loop
results=zeros([],3); count = 0 ; for i=1000:100:1500 for j=150:50:1608 [y,x]=min (ds(j:j+100,i)); ...

5 years ago | 0

| accepted

Answered
how to plot streamline
Try: skip = 2 ; % can be changed startx = X(1:skip:end,1:skip:end) ; starty = Y(1:skip:end,1:skip:end) ; ...

5 years ago | 2

| accepted

Answered
Extracting data from a Graph.
You may have a look on this: https://in.mathworks.com/matlabcentral/fileexchange/7173-grabit

5 years ago | 0

Answered
Finding the column of a matrix with the largest value
Read about the function max. Here you can specify the dimension in which you want a maximum value. Also max gives you the value ...

5 years ago | 1

Answered
¿How to evaluate an expression using symbolic functions and variables on it?
syms x h f(x) finalPolynomial; f(x) = sin(x) ; finalPolinomyal = ( f(x+h) - f(x-h) )/(2*h); finalPolinomyal = subs(final...

5 years ago | 1

| accepted

Answered
24H time from datetime('now')
t = datetime('now') ; t.Format = 'dd-MMM-uuuu HH:mm a'

5 years ago | 1

| accepted

Answered
how to convert .mat file to .csv file
Read about table and writetable. You can load matfile and convert the variables into a table and then write this into a csv file...

5 years ago | 1

| accepted

Answered
How to plot shaded areas with legend
Example; clc; clear all x = 1:10 ; y = rand(size(x)) ; figure hold on % Region1 area([x(1:4) x(1)],[y(1:4) y(1)]) a...

5 years ago | 0

| accepted

Answered
Merge data into one file
matFiles = dir('*.mat') ; N = length(matFiles) ; iwant = zeros([],22,N) ; for i = 1:N load(matFiles(i).name) ; ...

5 years ago | 0

| accepted

Answered
I have experimental data at different temperatures, how to fit the results and make predictions
You can use interp1 which does interpolation and give you value. Also you can fit a curve to the data using polyfit, read about ...

5 years ago | 0

| accepted

Answered
Help me collect selected data point values
Read about ginput, getpts.

5 years ago | 0

Answered
can you clarify this error
It seems the file: hRSMeasurements is not a function it is a code. Go inside the file, define your variables cell1,rxgridcell1 a...

5 years ago | 0

| accepted

Answered
Intersecting and non-intersecting box regions
Run a loop for each box and find the intersection points. Use this to get the intersection points. https://in.mathworks.com/ma...

5 years ago | 0

Answered
How to make plot like this in Matlab
You need to have boundary of India. This boundary will have (x,y) and use plot to plot the India map. To plot the colored boxe...

5 years ago | 0

Answered
Evaluating symbolic matrix equations
Read about double. A = subs(A, A, rand(20, 3)); A = double(A) ;

5 years ago | 0

Answered
Error in line X
clear, clf x=[0:10:1000]; y=2*(1)^2*(1-exp(-(x/100).^(1.4))); % <---- element by element operation % g=3*x; xlabel('R [a.u.]...

5 years ago | 0

| accepted

Answered
Error Importing Excel Data
T = readtable(myfile) ; S = T.(2); T = T.(1); b = bar(S, T);

5 years ago | 1

| accepted

Answered
How do I interpolate the remaining part of my signal?
These lines: xs = ~isnan(xt); ys = ~isnan(Fy); yi = interp1(xs,ys,xt, 'spline'); should be: % xs = ~isnan(xt); idx = ~isna...

5 years ago | 0

Answered
Can I get a 3D array from an image folder
img = dir('*.jpg') ; % give you image extensions n = length(img) ; I = zeros(n,938,512) ; for i = 1:n T = imread(img(i...

5 years ago | 0

| accepted

Answered
Finding the mean of data with different array sizes
You can get all those arrays into same size using interp1 and hen use mean.

5 years ago | 0

| accepted

Answered
How can I increase the size of an array that is already in the workspace with increments of 0.1?
You need to use interp1. Let A be your original array of size 45*2. dx = 0.1 ; x = A(:,1) ; y = A(:,2) ; xi = min(x):dx:...

5 years ago | 0

Answered
add another column to the end of matrix
x1=randi(5); y1=randi(5); time_e=randi([1 5]); Carr_veh = [rand(100,1),randi([0,1],100,1),randi([5,8],100,1),randi([5,8],100,...

5 years ago | 0

| accepted

Answered
How could I speed up this loop made to plot using the pcolor function?
A = rand(7,7,20001) ; [m,n,p] = size(A) ; [X,Y] = meshgrid(1:n,1:m) ; set(groot,'defaultAxesFontSize',12) h = pcolor(A(:...

5 years ago | 1

| accepted

Answered
Plot function and hold on feature not plotting one of my graphs
It looks like your red curve is in exact match with blue one. Try using different markers to confirm it.

5 years ago | 0

Answered
Create triangular matrix from vector
REad about triu and tril.

5 years ago | 0

| accepted

Answered
draw a max line in existing plot
DEfine the two points and use line.

5 years ago | 0

Answered
Need some help with my function.
function inverse_A=nonsingular(A) Determinant_A=det(A); if Determinant_A==0 inverse_A=[] disp('Matrix A does not hav...

5 years ago | 0

Answered
How to plot stacked variables with common x-axis?
Generate all the curves, make them a matrix and use waterfall.

5 years ago | 0

Answered
Rescaling curves by a factor to a single curve
Read about polyfit.

5 years ago | 0

Answered
How to add 10% normally distributed random error to the data?
Let A be your data. [m,n] = size(A) ; idx = randperm(m*n,round(m*n*10/100)) ; A(idx) = randn(size(idx)) ;

5 years ago | 0

Load more