# Join 2 NMF models where dictionaries has hierarchical structure

I have two NMF models $A = W_1A_{dict}$ and $B = W_2B_{dict}$ (where the $W$ represents weight coefficient matrix). What is a good way to join two NMFs if I know each column of $B_{dict}$ is summed up to be $A_{dict}$?

For $A_{dict}:$ \begin{bmatrix} 200 & 0 & 0\\ 0 & 0 & 0\\ 0 & 400 & 0\\ 0 & 0 & 500 \end{bmatrix}

For $B_{dict}:$ \begin{bmatrix} 0 & 70 & 70\\ 0 & 0 & 80\\ 90 & 0 & 0\\ 0 & 100 & 100\\ 110 & 110 & 0\\ 0 & 120 & 120\\ 0 & 0 & 130 \end{bmatrix}

The second column of $A_{dict} = 400 = 70+100+110+120$ form $B_{dict}$.

———

Additional info: I think with pre-knowledge of dictionary and observation data structure, the update rule should be better than deriving from the cost function of sum of 2 NMF: $D(A||A_{dict}W_{1}) + D(B||B_{dict}W_{2})$ where my $D$ is Kullback-Liebler divergence.

My real data is MS1 and MS2 spectra where MS2 is the fragment pattern of MS1 atom broken by some force. Each MS1 and MS2 is measured separately then $A_{dict}$ , $A$ and $B_{dict}$ , $B$ are different input.

For example, the column in MS1 dictionary has atom with mass/charge(m/z)=200. Each column of MS2 dictionary will be a fragment of 200 m/z.

The complicated thing here is the fragment set will not sum up to exactly 200. It has a rule to calculate anyway. For the element=200 m/z, the first set of possible fragments is 20.9, 30.2, 40.7, 50.0, 60.9 (along with other possible sets). And the most important point is some fragments won’t be detected in observation data. Probably, 20.9, 30.2, 50.0 are appeared. So, I think I have to separate column of each fragment and group them afterward. But to be simple, I wrote above the toy setting.

• Do you want to merge them together, as if they were trained at once? If you are certain that each column corresponds to the same atom, then just sum the values. Anyway, can you provide more details about the application? You will get a better answer. – jojek Jan 12 '18 at 11:09
• @jojek I answered and added additional info in the question. If there is something I should explain more, please let me know. – Jan Jan 12 '18 at 17:32