double Conversion to double from struct is not possible.
Mostra commenti meno recenti
Error using ==> double
Conversion to double from struct is not possible.
clc;
clear all;
x = load('S_chest.mat');
y = load('S_abdomen.mat');
A=zeros(size(x));
A(1,1)=x(1);
for n= 2:5955
A(n,1)=x(n);
A(n,2)=x(n-1);
end
What's wrong with that?
Risposte (1)
Andrei Bobrov
il 4 Set 2017
Modificato: Andrei Bobrov
il 5 Set 2017
x1 = load('S_chest.mat');
y1 = load('S_abdomen.mat');
x = x1.x;
y = y1.y;
A=zeros(size(x));
A(1,1)=x(1);
for n= 2:5955
A(n,1)=x(n);
A(n,2)=x(n-1);
end
or
x1 = load('S_chest.mat');
x = x1.x;
n = numel(x);
k = 5955;
A = toeplitz([x(1:k);zeros(n - k,1)],[x(k) 0]);
A(k+1,2) = 0;
Categorie
Scopri di più su Structures in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!