I cant solve this "Error using horzcat Dimensions of matrices being concatenated are not consistent." please help im new to MATLAB

조회 수: 3 (최근 30일)
Here is my code:
%This line of code will open a file dialog for image input%
clc;
close all;
[fname, path]= uigetfile ('.JPG','Open Image for training','Open Image file');
fname = strcat(path,fname);
im = imread(fname);
imshow(im);
title ('Input Image');
c = input ('Enter Class for this image(Enter number from 1 to 10)');
%%Feature Extraction
F = FeatureStatistical(im);
try
load db;
F = [F c];
db = [db;F];
save db.mat db
catch
db = [F c];
save db.mat db
end
If I try to run it I got this error:
Error using horzcat
Dimensions of matrices being concatenated are not consistent.
Error in Module1_training (line 19)
db = [F c];
I have 1x2x3 double for my F and 1 for c.
Please Help me.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Creating and Concatenating Matrices에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by