Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] (null) Column in markov matrix #69

Open
sergiotj opened this issue Jul 13, 2022 · 3 comments
Open

[BUG] (null) Column in markov matrix #69

sergiotj opened this issue Jul 13, 2022 · 3 comments
Assignees
Labels
bug Something isn't working

Comments

@sergiotj
Copy link

Describe the bug
Markov matrix is wrong in the (null) column. All the values are 0.

To Reproduce
Steps to reproduce the behavior:

  1. Create markov attribution
  2. Print markov matrix
  3. Look at values for (null) column
  4. See error

Expected behavior
That column should have the frequency of times that the other channels end in (null)

Screenshots
image

@sergiotj sergiotj added the bug Something isn't working label Jul 13, 2022
@sergiotj sergiotj changed the title [BUG] [BUG] (null) Column in markov matrix Jul 13, 2022
@Nathandsn
Copy link

Can you send us a full notebook file with this error or at least a print of the full matrix? I wasn't able to reproduce the issue...

What do you have at the "(null)" row? I'm asking because this seems to be the expected behavior of the '(null)' row, your matrix may just be the transpose.

@Nathandsn Nathandsn self-assigned this Oct 13, 2022
@MoritzMohrStade
Copy link

I discovered the same behavior as @sergiotj for all different datasets I tried, even when using a random dataframe with:
attributions = MAM(random_df=True)
The column (null) shows 0s for every row except the (null) to (null) transition. My expectation would be to have the non-null values for probabilities where people did not buy.
This is a huge bug because it would imply that there are no non-converting transitions that end in (null).

My colab for the random dataframe:
https://colab.research.google.com/drive/1_FEcffn-pdh4r9xo5BPfaTQ3q2T9b7k-?usp=sharing

To reproduce use:

  • GA4 Public BigQuery Dataset for the Google Merchandise Store
  • random dataframe

@yanMHG
Copy link

yanMHG commented May 15, 2024

The root of the issue is in the conversion_value_as_frequency parameter of the attribution_markov method.

When the value of the parameter is True, which is the default, the method does not count the transitions ending in (null), since their conversion value is 0. To circumvent the issue, the value must be set to False, which forces standard counting.

Technically not a bug, but this choice of default behavior does feel a bit awkward/unexpected to me, specially because it does not seem to apply to the examples in the README.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants