# Measuring Polarization in Online Debates
## 2 User-Based Model for Reddit
We define \(\mathcal{S}\) as the mapping \(\mathcal{S}:\mathcal{C}\rightarrow[-1,1]\) that assigns to every node \(C_{i}\in\mathcal{C}\) the value \[\mathcal{S}(C_{i})=\frac{\sum_{c\in C_{i}}S(c_{i})}{|C_{i}|}\] _in the real interval \([-1,1]\) that expresses the side of the user_ \(u_{i}\) _with respect to the root comment, from strictly disagreement (_\(-1\)_) to strictly agreement (_\(1\)_), going through undecided opinions (_\(0\)_)._
* \(\mathcal{W}\) _is an interaction weighting scheme for_ \(\mathcal{E}\) _that expresses both the ratio of positive interactions between the users' opinions and the overall sentiment between users by combining the individual sentiment values assigned to the responses between their comments. Let_ \(\oplus\) _be an aggregation operator of dimension_ \(n\) _on the real interval_ \([-2,2]\)_, i.e., a bounded, monotonic, symmetric, and idempotent mapping_ \(\oplus:[-2,2]_{n}\rightarrow[-2,2]\)_. We define_ \(\mathcal{W}\) _as the mapping_ \(\mathcal{W}:\mathcal{E}\rightarrow([0,1]\times[-2,2])\) _that assigns to every edge_ \((C_{i},C_{j})\in\mathcal{E}\) _the pair of values_ \((p,w)\in([0,1]\times[-2,2])\) _defined as follows:_ \[p=\frac{|(c_{1},c_{2})\in E\cap(C_{i}\times C_{j})\text{ with }W(c_{1},c_{2})>0|}{|(c_{1},c_{2}) \in E\cap(C_{i}\times C_{j})|}\text{ and }\] \[w=\oplus_{\{(c_{1},c_{2})\in E\cap(C_{i}\times C_{j})\}}W(c_{1},c_{2}),\] _where_ \(p\) _expresses the ratio of positive answers from the user_ \(u_{i}\) _to the user_ \(u_{j}\) _in the debate, and_ \(w\) _expresses the overall sentiment of the user_ \(u_{i}\) _regarding the comments of the user_ \(u_{j}\)_, from highly negative (_\(-2\)_) to highly positive (_\(2\)_). Only the nodes and edges obtained by applying this process belong to_ \(\mathcal{C}\) _and_ \(\mathcal{E}\)_, respectively._  
Notice that if a user only responds to the news of the debate (the root comment \(r\)), the user is mapped in the UDebG to a node in \(\mathcal{C}\) with zero output degree denoting that the user starts no discussion with other users. In addition, users whose comments do not generate answers from other users are represented with nodes whose input degree is zero. Therefore, isolated nodes may appear in the UDebG that correspond to users who have neither generated nor participated in the debate, that is, users that have only answered to the news and whose opinions can be considered to be accepted by all users since they have not been discussed yet. In the UDebG, each node denotes a user's opinion, and relationships between nodes are mined from the prevailing sentiment among the aggregated comments of those nodes. For instance, if we instantiate the aggregation operator \(\oplus\) to the minimum function, we obtain a pessimistic interpretation of the degree of agreement and disagreement among users since it represents the fact that in a debate with multiple negative and positive responses from one user to another, a pessimistic analysis focuses on the most negative response and in the case of multiple positive responses, on the softest positive response. Similarly, the maximum operator corresponds to an optimistic interpretation and the mean operator to a more realistic interpretation based on an intermediate weight. Furthermore, the ratio of positive answers is either \(1\) or \(0\), only for strictly agreement or disagreement relationships, respectively, between users' opinions; thus, the ratio of positive answers is a value in \((0,1)\) only for ambivalent relationships. Finally, since the edges between nodes in the UDebG can reflect ambivalent relationships between users' opinions, in our current user-based model, we do not consider indirect (transitive) relationships between users, and thus, the UDebG shows interactions between users only if there is enough evidence of such relationships through direct answers between authors' comments.