I have 5-channel files that I am running through a PSD analysis in PAMGuide, but in order to complete my analyses, I need to know which channel it is using to calculate (I presume it is not using an average of all five channels since that wouldn't make sense with dBs being on a logarithmic scale). Does it just use the first-channel? Does it arbitrarily choose randomly?
1 Answer
Fortunately, Matlab Apps are available as source code.
So, let us see: In line 158,159 of PAMGuide.m we find
xbit = xbit(:,1); %In case of multichannel input, selects
%1st channel (use xDIG(:,2) for 2nd, etc.)
which answer your question: it is 1st channel.
To select other channels you have to xbit(:,1) to xbit(:,2) for second channel etc. (Note: I consider xDIG to be a typz or left over of an earlier version and should read xbit, otherwise it would not make sense)
There is no menu-entry for selecting the channel, but it is easy to modify the source code. And if it is really important you can add a small text-box onto the menu and change channel from GUI.
EDIT: the real location to edit is PG_Func line 235! It seems that the statement in PAMGuide.m is of no impact as xbit will be cleared a little bit later.
Comment: PAMGuide is nearly 10 years old without any visible maintenance on Sourceforge. Maybe time to replace it?
-
$\begingroup$ Regarding the suggestion to replace PAMGuide: I've got a different perspective. PAMGuide is not perfect, but what software is? The OP is evidence that PAMGuide is still being used and people are getting value from it. Furthermore, it appears to be published under a Creative Commons license (though this isn't entirely clear), and with code available. So, instead of replacing it, which could be costly, it might be better for many to fork it and fix the deficiencies. But if newer is a requirement for you then it's probably worth checking out MANTA doi.org/10.3389/fmars.2021.703650 $\endgroup$– Brian Miller ♦Commented Oct 2 at 1:38
-
$\begingroup$ Agree, no software is perfect, that is why maintenance may be needed. I would also agree, that, if there is SW that does what you wanted to do, use it. But the OP also indicates that SW is not quite the tool that was looked for. Having something like channel selection hard coded in multiple locations and not parameterized is a little bit too much for most users. I also prefer that fixes are done in one place and not by many individuals. Concerning MANTA, it seems that only executables are easily available, so inspecting source-code to answer BE questions is difficult. $\endgroup$– WMXZCommented Oct 2 at 5:21