matlab 将某文件夹的内容复制到零一文件下
作者:互联网
%% 清空
close all;
clear;
clc;
%% 选择文件路径(复制某文件夹下部分文件夹到其他路径)
folder = uigetdir('C:\Users\wjn\Desktop','请选择文件夹');
%% image0
image0Folder=[folder '\image0'];
image0File=dir(fullfile(image0Folder,'*.png'));
count=length(image0File);
%% 遍历image0
for i = 1:count
name = image0File(i).name;
image0Path = [image0Folder,'\',name];
copyfile(image0Path,'C:\Users\wjn\Desktop\image0');
end
标签:零一,复制到,name,%%,image0File,Desktop,文件夹,matlab,Users 来源: https://www.cnblogs.com/wjn1996/p/12022503.html