답변 있음
Compact way to plot data with relative colors and legend
% Input a = {'marathon', 1, 4; 'bank holiday', 3, 6; 'bank holiday', 2, 1; 'concert', 0, 4; 'regatta', ...

6달 전 | 1

답변 있음
Bode Plot options to graph
H = tf([1 0.1 7.5],[1 0.12 9 0 0]); [mag,phase,wout] = bode(H); subplot(211); plot(wout, squeeze(mag(1,1,:))) subplot(212); p...

6달 전 | 0

답변 있음
How to create a for loop to go through data arrays?
%data = load('file.mat'); data.laser1.pulse=randn(10,1); data.laser2.pulse=randn(10,1); data.laser3.pulse=randn(10,1); dat...

6달 전 | 0

| 수락됨

답변 있음
How can i estiamte the local distance between two boundaries at each point ??

6달 전 | 0

| 수락됨

답변 있음
Interindividual distance from trajectories

6달 전 | 0

| 수락됨

답변 있음
how to create gray scale gradient image?
a = (-5:0.1:5)'; b = exp(-a.^2/2); x = repmat(b, [1 512]); imagesc(x); colormap(flip(gray(512)))

6달 전 | 0

답변 있음
Structure that contain an array of points with string names and coordinates
Use array of structure % Define structure points_data = struct('PointID', [], 'Coordinates', [], 'Names',[]); % To have repea...

6달 전 | 0

| 수락됨

답변 있음
Structure of array: deletion of null elements
exp_value(exp_value.f_avg(:, 1)==0) = [];

6달 전 | 0

답변 있음
How can I create a for loop?
n = 20; B = zeros(n, 1); C = zeros(n, 1); for i=1:n a1=1/((1+i/100)^1); a2=1/((1+i/100)^1); a50=(((1+i/100)^...

6달 전 | 0

| 수락됨

답변 있음
Convert RGB image into 8 bit rgb image

6달 전 | 0

| 수락됨

답변 있음
Partitioning data out of .txt files

6달 전 | 0

| 수락됨

답변 있음
How to make a matrix from several column vector
a = rand(1,1); b = rand(10,1); c = rand(100,1); % you are not able to combine them into a matrix as you sepcified since the...

6달 전 | 0

답변 있음
How to obtain mean of columns in multiple cells?
% Generate data for i=1:5 a{i} = randn(3439, 72); end % find means s = zeros(size(a{1})); for i=1:5 s = s + a{i...

6달 전 | 0

| 수락됨

답변 있음
How to interpolate gridded data for contourf?
doc fillmissing

6달 전 | 0

답변 있음
Implementation of fractional delay filter from scratch in matlab
If you are looking for source code of fractional delay, check out this and its accompanying codes: T. I. Laakso, V. Valimaki, M...

6달 전 | 0

답변 있음
Solve matrix equations using loop
The equations you have: You want to solve it for , and . You need to rearrage the equations: Now you solve this new syst...

6달 전 | 0

답변 있음
How to find FWHM from this?
Your data has no half power points so you cannot find fwhm. load(websave("fwhmdata.mat", "https://www.mathworks.com/matlabcentr...

6달 전 | 0

답변 있음
How to accurately compute the phase lag between two time series with same sampling frequency.

6달 전 | 1

| 수락됨

답변 있음
Graphing a two variable limit
x= -0.5:.01:0.5; y = 0.5:.01:1.5; [xx, yy] = meshgrid(x, y); zz = acos(xx./yy)./(1+xx.*yy); %zz = nan(size(xx)); % idx = ab...

6달 전 | 1

| 수락됨

답변 있음
How to fix error "Array indices must be positive integers or logical values."
function xc = mybisect(f, a, b, tol) format longg; a_vals = zeros(a, length(tol)); b_vals = zeros(b, length(tol)); c_vals = ...

6달 전 | 1

| 수락됨

답변 있음
strings in conditional statments
l = input('Do you want to plot: ', "s"); % s for string if l == "yes" % string comparison instead of cha...

6달 전 | 1

| 수락됨

답변 있음
Is my matlab code for the sinc signal below correct.
%************ Variable declaration****************** t = -20:0.1:20; p = -10:1:10; signal = zeros(1,length(t)); %for spped al...

6달 전 | 0

답변 있음
How to plot the convolution integral of two functions
Use symbolic math: syms x y h tau %x = 0:0.5:10; y = exp(-x); % use -1 and -2 to ensure convolution exist h = exp(-2...

6달 전 | 1

답변 있음
Error: Edge vector must be monotonically non-decreasin with isosurface
Nx = 32; Ny = 32; Nz = 32; Lx = 2*pi; Ly = 2*pi; Lz = 2*pi; x = (0:Nx-1)/Nx*2*pi; % x coordinate in Four...

6달 전 | 0

| 수락됨

답변 있음
How to plot envelope of a signal
load t.mat load signal.mat whos plot(t, signal); hold on [yupper,ylower] = envelope(signal,1000, 'peak'); plot(t, yupper, ...

6달 전 | 0

| 수락됨

답변 있음
Cross Correlation lag issue
P2 = randn(10, 1); P3 = [zeros(5, 1); P2]; % P3 is P2 delayed by 5 [xc2,lags2] = xcorr(P2,P3); plot(lags2, xc2) [rho2,imax...

6달 전 | 0

답변 있음
Adding XYZ axis in RGB colors in the corner of a plot
plot(rand(10,1)) annotation('arrow', [0.8, 0.7], [0.8, 0.75], 'Color', 'r') annotation('textbox', [0.68, 0.70 0.05 0.05], 'Str...

6달 전 | 0

| 수락됨

답변 있음
How to label a structure name in a loop
low.t1 = 2; low.t2 = 3; for i=1:2 data = low.("t"+i) end

6달 전 | 0

답변 있음
Reorder vector without for loop
A = randn(583200, 10); B =reshape(A, 540, [], 10); B = permute(B, [2 1 3]); B = reshape(B, 583200, 10); whos % To verif...

6달 전 | 0

답변 있음
using subplot in bar , how to adjust bar width
x1 = [1 2 3]; y1 = [1 2 3 ]; x2 = [1 2 3 4 5]; y2 = [1 2 3 4 5]; % Make xlim same so that the bar width is the same h1= s...

6달 전 | 0