|
From: theozh <th...@gm...> - 2017-05-26 05:16:55
|
> >> Can you fill in that idea a bit? Do you envision this as a binary test > 'does string A match regexp B? yes/no'? Something more complicated? > Honestly, it's not thought through thoroughly. Just when trying to extract the filename from the full filename I thought it would be nice if in above example an expression something like |.*\\Data(.*)\.dat| directly returned the "007". Well, now I have a rather compact solution. On the otherhand, when creating a list of data files to be plotted it would be nice if the search pattern in FileList = system(dir /B /S Data*.dat) could be a bit more sophisticated than a simple wildcard. I know that this is a Windows system command and gnuplot doesn't have any influence on it. Although, gnuplot could filter it further and/or "distribute" the files to sublists which are then plotted in a single plot or multiplot environment. I need to find a practical example to illustrate. But probably one can also find a solution with the already existing gnuplot commands. I guess a binary regexp test together with the ternary operator could be quite powerful. Well, as I said, it's not fully thought out... |