1 #pragma rtGlobals=3// Use modern global access method and strict wave access. 3 #pragma IgorVersion = 6.2 4 #pragma ModuleName = PearlTools 5 #include "pearl-gui-tools" 45 string IterateWaves(
string matchStr, funcref iterator,
string sdata){
55 string wlist = WaveList(matchStr,
";",
"")
56 variable n = ItemsInList(wlist,
";")
58 for (i = 0; i < n; i += 1)
59 wave w = $(StringFromList(i, wlist,
";"))
75 print getdatafolder(1)
79 string IterateDataFolders(
string matchStr, funcref iterator,
string sdata,
string progress_title = defaultValue){
94 if (ParamIsDefault(progress_title))
97 variable show_progress = strlen(progress_title) > 0
99 dfref origdf = GetDataFolderDFR()
102 variable abort_req = 0
105 variable ndf = CountObjectsDFR(origdf, 4)
111 objName = GetIndexedObjNameDFR(origdf, 4, index)
112 if (strlen(objName) == 0)
115 if (stringmatch(objname, matchstr))
123 curdf = $(
":" + objname)
124 iterator(curdf, sdata)