0
$\begingroup$

I have two matrices, $A$ and $B$, each of size $n\times m$, where $n$ is discrete time points, and $m$ are the variables measured (specifically, $n$ are dates and $m$ are investments measured in dollars) by two different companies (company $a$ and $b$).

I have introduced a time offset $k$ in $B$, such that the row $j$ of $A$ represents all investments present at time point $j$, while the row $j$ of matrix $B$ represents the investments present at time $j+k$. Now, I want to determine the degree to which $A$ is similar to $B$ (my goal is to find some measure of information "flow" from company $a$ to company $b$).

I'm currently measuring the mean cosine similarity between corresponding rows in $A$ and $B$. However, does this make sense, or is there a better method?

$\endgroup$
3
  • $\begingroup$ Cosine similarity is the gold-standard for matrix comparison, you sound dead-on to me. It sounds like you may now be wondering what do to with a vector of n cosine similarities. Is that correct? $\endgroup$ Feb 22, 2021 at 20:28
  • $\begingroup$ Thanks @TannerPhillips. That is helpful. At the moment I am calculating the corresponding cosine similarities as defined here and then taking the mean of the resulting vector (of length $n$). Also, $A$ and $B$ are row-normalized to sum to 1 before this. Does that make sense? $\endgroup$
    – Arthur D.
    Feb 22, 2021 at 20:43
  • $\begingroup$ Yeah, without seeing the data that seems to make sense. Row normalization is a really good idea here; it will probably save you a lot of potential headache. $\endgroup$ Feb 23, 2021 at 23:14

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.