<p>If the issue is just in setting up PAMGuard to do what you need, I think the below should help you. If it is a bug or other issue and you've already done this, then maybe you can share what you have for these settings as well.</p>
<p><strong>STEP 1. To batch process multiple files:</strong></p>
<ul>
<li>Select &quot;Audio file folder or multiple files&quot; as the Data Source Type in the Sound Aquisition settings window. To access that window (which you have shown in your first screenshot, but just for others who might find this helpful) select Settings &gt; Sound Aquisition and then click on &quot;Data Source Type&quot; to access the dropdown menu</li>
<li>Then, when you browse for the files, you can either select an entire folder, or select multiple files by holding down ctrl and clicking all the files you want</li>
</ul>
<p><a href="https://i.sstatic.net/MiZUc.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/MiZUc.png" alt="screenshot showing the options for the Sound Aquisition module, Data Source Type drop down menu" /></a></p>
<p><strong>STEP 2.</strong><br />
You also need to set up an output database and binaries folder to save all your results in one place. It saves them as an SQL database, but the tools that @Chloe pointed to in her answer will allow you to read that database into Matlab.</p>
<ul>
<li><p>Add the Database and Binaries modules:</p>
<ul>
<li>File &gt; Add Modules &gt; Utilities &gt; Database</li>
<li>File &gt; Add Modules &gt; Utilities &gt; Binary Storage</li>
</ul>
</li>
<li><p>Set the save locations for the database and binaries:</p>
<ul>
<li>There will now be two additional lines in the File drop down menu</li>
<li>Go to Database &gt; Database Selection, click &quot;Browse/Create&quot; and a window will pop up where you can navigate to where you want the database saved and give it a name. If that database does not exist, just type a name in the File Name box and select &quot;Open&quot; and PAMGuard will prompt you to create that database.</li>
<li>Go to File &gt; Binary Store Options and then click &quot;Browse&quot; to set the folder where you want all the binary files to be saved. Typically, I have a &quot;databases&quot; folder within my project analysis folder where I save all the database files, then a &quot;binaries&quot; folder where I have a folder for the corresponding binaries for each of the databases that I have in the &quot;databases&quot; folder</li>
</ul>
</li>
</ul>

CC BY-SA 4.0
2022-11-21T21:49:06.793Z
Thank you very much, now it seems that  it works (at least I have the data in those folders). Now I have to open it with Matlab.
Anaa
CC BY-SA 4.0
2022-11-21T16:04:38.097Z
2023-04-19T11:51:16.283Z
2023-04-19T11:51:16.283Z
selene
<p>Not quite enough details to know what the issue specifically is, but go here to download the library for bringing PAMGuard binary files into Matlab:
<a href="https://github.com/PAMGuard/PAMGuardMatlab" rel="nofollow noreferrer">https://github.com/PAMGuard/PAMGuardMatlab</a>. Also, have you played with the <em>Click Detection &gt; Detection Parameters</em> settings so that they'd capture whatever clicks you're interested in?</p>

CC BY-SA 4.0
2022-11-21T21:55:05.730Z
Thank you for the link Chloe, I have downloaded the library. Now I have to figure out how to open the saving results in Matlab. About the detection parameters that you mention... I didn't use them because that module doesn't work for my recordings. I'm using the click classification part, filtering by click length and by frequency range and it works.
Anaa
CC BY-SA 4.0
2022-11-24T14:10:36.330Z
Hi Anaa, OK glad you've made some progress... though note that the click classification module will only work if the click detection module is also working (because it can't classify things it can't detect).
Chloe
CC BY-SA 4.0
2022-11-21T11:32:51.693Z
2022-11-21T11:32:51.693Z
Chloe
<p>The database I want to analyze contains hundreds of audio files of 1 minute each and I wanted to process them in PAMGuard as quickly as possible and also to be able to save the result in a single file if possible that can be read in Matlab.</p>
<p>The settings of my sound acquisition module are the following:
<a href="https://i.sstatic.net/76bei.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/76bei.png" alt="enter image description here" /></a></p>
<p>The module I'm using is the click detector, (the click classification part).
<a href="https://i.sstatic.net/kkadB.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/kkadB.png" alt="enter image description here" /></a></p>
<p>I would really appreciate if someone could help me or give me an idea of ​​how to proceed.</p>
<p>Thank you in advance.</p>

CC BY-SA 4.0
2022-11-18T10:05:01.903Z
Can you be more specific about the difficulty you are facing? Is the challenge with configuring the program, or with getting settings right on a particular module? This is a task that PAMguard is totally capable of, and can save the data as binary files (that can be read into R or Matlab) and/or to a database.
Chloe
CC BY-SA 4.0
2022-11-18T16:36:00.033Z
Following on @Chloe some helpful info would be: 
what modules are you using for your processing (click detector, etc?) 
have you set up the sound aquisition module?
selene
CC BY-SA 4.0
2022-11-20T21:38:05.320Z
The module I'm using is the click detector. I uploaded a screenshot of my sound acquisition module settings. I'd like to save the resulting data in a structure that can be read in Matlab
Anaa
<pamguard><processing><files><audio>
How could I process multiple audio files in PAMGuard?
# How could I process multiple audio files in PAMGuard?

(Asked by: username_0 on 2022-11-17)

The database I want to analyze contains hundreds of audio files of 1 minute each and I wanted to process them in PAMGuard as quickly as possible and also to be able to save the result in a single file if possible that can be read in Matlab.

The settings of my sound acquisition module are the following:
[![enter image description here](https://i.sstatic.net/76bei.png)](https://i.sstatic.net/76bei.png)

The module I'm using is the click detector, (the click classification part).
[![enter image description here](https://i.sstatic.net/kkadB.png)](https://i.sstatic.net/kkadB.png)

I would really appreciate if someone could help me or give me an idea of ​​how to proceed.

Thank you in advance.

**Tags:** pamguard, processing, files, audio

> **Comments:**
> **username_1**: Can you be more specific about the difficulty you are facing? Is the challenge with configuring the program, or with getting settings right on a particular module? This is a task that PAMguard is totally capable of, and can save the data as binary files (that can be read into R or Matlab) and/or to a database.  
> **username_2**: Following on @username_1 some helpful info would be:  what modules are you using for your processing (click detector, etc?)  have you set up the sound aquisition module?  
> **username_0**: The module I'm using is the click detector. I uploaded a screenshot of my sound acquisition module settings. I'd like to save the resulting data in a structure that can be read in Matlab  

---

## 2 answers

### Answer by username_2 on 2022-11-21. Score: 3

If the issue is just in setting up PAMGuard to do what you need, I think the below should help you. If it is a bug or other issue and you've already done this, then maybe you can share what you have for these settings as well.

**STEP 1. To batch process multiple files:**

* Select "Audio file folder or multiple files" as the Data Source Type in the Sound Aquisition settings window. To access that window (which you have shown in your first screenshot, but just for others who might find this helpful) select Settings > Sound Aquisition and then click on "Data Source Type" to access the dropdown menu
* Then, when you browse for the files, you can either select an entire folder, or select multiple files by holding down ctrl and clicking all the files you want

[![screenshot showing the options for the Sound Aquisition module, Data Source Type drop down menu](https://i.sstatic.net/MiZUc.png)](https://i.sstatic.net/MiZUc.png)

**STEP 2.**  
You also need to set up an output database and binaries folder to save all your results in one place. It saves them as an SQL database, but the tools that @username_1 pointed to in her answer will allow you to read that database into Matlab.

* Add the Database and Binaries modules:

  + File > Add Modules > Utilities > Database
  + File > Add Modules > Utilities > Binary Storage
* Set the save locations for the database and binaries:

  + There will now be two additional lines in the File drop down menu
  + Go to Database > Database Selection, click "Browse/Create" and a window will pop up where you can navigate to where you want the database saved and give it a name. If that database does not exist, just type a name in the File Name box and select "Open" and PAMGuard will prompt you to create that database.
  + Go to File > Binary Store Options and then click "Browse" to set the folder where you want all the binary files to be saved. Typically, I have a "databases" folder within my project analysis folder where I save all the database files, then a "binaries" folder where I have a folder for the corresponding binaries for each of the databases that I have in the "databases" folder

> **Comments:**
> **username_0**: Thank you very much, now it seems that  it works (at least I have the data in those folders). Now I have to open it with Matlab.  

---

### Answer by username_1 on 2022-11-21. Score: 2

Not quite enough details to know what the issue specifically is, but go here to download the library for bringing PAMGuard binary files into Matlab:
<https://github.com/PAMGuard/PAMGuardMatlab>. Also, have you played with the *Click Detection > Detection Parameters* settings so that they'd capture whatever clicks you're interested in?

> **Comments:**
> **username_0**: Thank you for the link username_1, I have downloaded the library. Now I have to figure out how to open the saving results in Matlab. About the detection parameters that you mention... I didn't use them because that module doesn't work for my recordings. I'm using the click classification part, filtering by click length and by frequency range and it works.  
> **username_1**: Hi username_0, OK glad you've made some progress... though note that the click classification module will only work if the click detection module is also working (because it can't classify things it can't detect).  

---

