⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 filecombination.m

📁 神经网络源码可应用于遥感图像分类
💻 M
字号:
function filecombination()
%数据格式转换程序。将三个波段象元灰度值写入一个文件
%disp('Please input the data file[path][filename]:');
%file1=input('the 1 band file name:','s');
%file2=input('the 2 band file name:','s');
%file3=input('the 3 band file name:','s');
%file4=input('the 4 band file name:','s');
%file5=input('the output file name:','s');
file1='g:\lfx\newtask\exportedata\txtsx-1.txt';
file2='g:\lfx\newtask\exportedata\txtsx-2.txt';
file3='g:\lfx\newtask\exportedata\txtsx-3.txt';
file4='g:\lfx\newtask\exportedata\txtsx-total.txt';
fpa=fopen(file1,'rt');
fpb=fopen(file2,'rt');
fpc=fopen(file3,'rt');
fpd=fopen(file4,'wt');
%fpe=fopen(file5,'wt');
while(~(feof(fpa)|feof(fpb)|feof(fpc)))
	[band_A,count1]=fscanf(fpa,'%f',[1,1]);
	[band_B,count2]=fscanf(fpb,'%f',[1,1]);
	[band_C,count3]=fscanf(fpc,'%f',[1,1]);
	class=[band_A,band_B,band_C];
	fprintf(fpd,'%4d',class);
end
fclose('all');
disp('The programe end');

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -