Read specific column from the text file and how to store the values into the matrix/vector?

Più risposte (1)

clc;
data=load('text_feat.txt');
bias=data(:,1);
bias=bias';
feature=data(:,2:5);
[row col]=size(feature);
F=zeros(row,col);
for i=1:row
for j=1:col
F(i,j)=F(i,j)+feature(i,j);
end
end
disp(size(F));

Categorie

Scopri di più su MATLAB in Centro assistenza e File Exchange

Tag

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by