Mixpanel Community Icon

How to Exclude Not in... Results from Mixpanel Cohorts

·
·

Hi community, I'm pretty new to mixpanel and I have an issue with the results I get on my metrics charts: I'm creating different cohorts using clients emails to separate them by company. When I get the results I keep getting the "Not in..." results I'm not interested in. Is there a way to get rid of these results permanently? Am I doing something wrong? thank you for your help in advance!

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    I'm not sure if this does what you want, but I use regex to pull the "email domain" from our emails. And use that to breakdown a report. I then use "is set" as a filter to get just those where the email domain is set

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·
  • Avatar of Sergio I.
    Sergio I.
    ·
    ·

    Thank you for your help Andrew S.. I not an expert on mixpanel and not sure I understand what you mean. Maybe if I clarify: I have a list of companies that I need to separate by their emails, I created cohorts for each company including their emails as the filter. I need to see those users by client separate in my charts Does these imgs make sense?

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    I follow now. Yeah, there is an "oddity" with cohorts where you get the "in" and "not in" in your breakdowns. I tend not to use cohorts that way.

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    So give this a try. create your insight. On the breakdown, create a custom property (the + in the right corner). Enter a formula like this:

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    REGEX_EXTRACT(@"""{"label":"Email","propertyDefaultType":"string","resourceType":"user","type":"string","value":"$email"}"""@, "(?<=@)[^.]+(?=.)")

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    (you should be able to copy/paste if you have a field named "Email" like I do.

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    That formula takes whatever is after @ and before . and makes the results that detail (so gmail if xxx@gmail.com).

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    That will then breakdown with that custom property.

  • Avatar of Andrew S.
    Andrew S.
    ·
    ·

    If you prefer to do custom naming, you can create a custom property that combines the regex (although you'd use regex_match) with an IFS so you can say in pseudocode, "If RegexMatch has "gmail" Then "Google", if ....

  • Avatar of Sergio I.
    Sergio I.
    ·
    ·

    fantastic! thank you very much Andrew S. I'll try it