필터 지우기
필터 지우기

parfor + loop problem

조회 수: 1 (최근 30일)
Farz Tak
Farz Tak 2016년 11월 8일
답변: Walter Roberson 2016년 11월 8일
Hi ,
I am trying to run this code to download data from ftp server. It says "too many argument even if I put the inter-loop inside a function. Any idea why this is happening? Thanks.
clc;clear all;close all;clear classes;
ftpobj = ftp('arthurhou.pps.eosdis.nasa.gov','farzaneh_takbiri@yahoo.com','farzaneh_takbiri@yahoo.com');
year={'2015'};
month={'01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12'};
day = eomday(2015, 1:12);
path_V1=['/gpmdata/',year{1}];
outputt1 = ['/mnt/lustre2/efoufoula/takbi001/GPROF/',year{1}];
name = ['2A.GPM.GMI.GPROF*','.V04A.HDF5'];
parfor j=2:size(month,2);%%
path_V2=[path_V1,'/',month{j}];
outputt2 =[outputt1,'/',month{j}];
for k=1:day(j)
path_V = [path_V2,'/',sprintf('%02.0f', k),'/','gprof','/'];
outputt = [outputt2,'/',sprintf('%02.0f', k),'/'];
mkdir(outputt);
cd(ftpobj2,path_V);
pasv(ftpobj2);
mget(ftpobj2,name,outputt);
end
% ftp_get(day, path_V2, outputt2, name, ftpobj, j) ;
end

답변 (1개)

Walter Roberson
Walter Roberson 2016년 11월 8일
You use
cd(ftpobj2,path_V);
but you do not define ftpobj2.

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by