Hello,
I am trying to automatize my process via script. However, I have a lot of difficulties with the names BrainStorm automatically gives the files on the Hard Disk (e.g. time stamps). If I try to manually rename the files on the HDD or with other Matlab functions Brainstorm no longer recognizes them. I was wondering if there is a way to correctly rename them through Brainstorm.
Thank you,
Irene
Hi Irene,
Renaming files manually in the Brainstorm database is not recommended. As you may have seen connections between files are broken, as these are also saved in the contents of the .mat
files.
Can you provide more information on what you aim to do with renaming the files?
There may be other solutions already built in Brainstorm to achieve your goal
Best,
Raymundo
1 Like
Hello,
For instance if I import 3 different EEG recordings in the same folder, even though I renamed them from the GUI to tell them apart, on the HDD they are called data_block001, data_block001_02 and so on. This is a problem because it means that from the script I can tell which recording is which just because I know the order in which I imported them. Also if I apply the same process to all of the recordings the results of the process are all named results+timestamp, again I can tell which result belongs to which datablock just because I know in which order I processed them. If I could rename the files it would be much easier to tell them apart.
Best,
Irene
Thanks for the context.
Check the following two suggestions on how to do so:
Just to be in the same page, these are the definitions I use for the text below:
- file path: the file name in the HDD
- file name the file name displayed in the Brainstorm GUI
Option 1.
Use the process File > Add tag and select either Add to file path or Add to file name and file path. With this your recordings will have extra information in their file paths.
Just be mindful that adding a tag in the file path, must be done just after importing, i.e., before any dependent file (PSD, sources, TF maps, etc) is computed.
Option 2
Do not modify the file path at all, just change the file name (names in the Brainstorm DB tree), either with the process File > Set name or by adding tags to the file name File > Add tag. Then you can use the process **File > Select files: TYPE **
The output of the process will have the file paths for the requested files.
1 Like
Than you for you answer! I will try.