Home > p2plib > getmaxlab.m

getmaxlab

PURPOSE ^

get maximal label in dir pre

SYNOPSIS ^

function mlab=getmaxlab(pre)

DESCRIPTION ^

 get maximal label in dir pre

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function mlab=getmaxlab(pre)
0002 % get maximal label in dir pre
0003 dn=[pre '/p*.mat'];c=dir(dn);mlab=0;
0004 for j=1:length(c)
0005     cn=c(j).name;lab=cn(2:length(cn)-4);lab=str2num(lab);
0006     if lab>mlab; mlab=lab; end
0007 end

Generated on Wed 15-Aug-2012 10:09:15 by m2html © 2005