  The recent report of an association of the gravitational-wave (GW) binary
black hole (BBH) merger GW190521 with a flare in the Active Galactic Nuclei
(AGN) J124942.3+344929 has generated tremendous excitement. However, GW190521
has one of the largest localization volumes amongst all of the GW events
detected so far. The 90\% localization volume likely contains $7,400$
unobscured AGN brighter than $g \leq 20.5$ AB mag, and it results in a $\gtrsim
70\%$ probability of chance coincidence for an AGN flare consistent with the GW
event. We present a Bayesian formalism to estimate the confidence of an AGN
association by analyzing a population of BBH events with dedicated follow-up
observations. Depending on the fraction of BBH arising from AGNs, counterpart
searches of $\mathcal{O}(1)-\mathcal{O}(100)$ GW events are needed to establish
a confident association, and more than an order of magnitude more for searches
without followup (i.e, using only the locations of AGNs and GW events).
Follow-up campaigns of the top $\sim 5\%$ (based on volume localization and
binary mass) of BBH events with total rest frame mass $\ge 50~M_\odot$ are
expected to establish a confident association during the next LIGO/Virgo/KAGRA
observing run (O4), as long as the true value of the fraction of BBH giving
rise to AGN flares is $>0.1$. Our formalism allows us to jointly infer
cosmological parameters from a sample of BBH events that include chance
coincidence flares. Until the confidence of AGN associations is established,
the probability of chance coincidence must be taken into account to avoid
biasing astrophysical and cosmological constraints.
