# Addressing the Cold-Start Problem in Recommender Systems Based on Frequent Patterns
## 3 Proposed Methodology  
In this work, a methodology is proposed to tackle the Cold-start recommendation problem, as an instance of the sparsity problem, including the extreme case of the _out-of-matrix prediction_, i.e., the recommender system must recommend products to a new user (or to detect users that might be interested in a new product). Most of the related work concerns the _in-matrix prediction_, where there are a few transactions related to new users. The proposed methodology tries to tackle the _out-of-matrix prediction_ problem as well and at the same time to handle the general sparsity problem by increasing the density of the initial user-product matrix. The pseudo-code of the proposed methodology (Algorithm 1) along with an illustration of the corresponding steps (Figure 1) are shown in what follows. ```
Step 1: Input  The set of users \(U=\left\{u_{1},\ldots,u_{nofp}\right\}\), where \(nofu\) is the number of users  The set of products \(P=\left\{p_{1},\ldots,p_{nofp}\right\}\), where \(nofp\) is the number of products  The \((nofu\times c)\) user matrix \(UM=\left\{(u_{i},u_{i1},\ldots,u_{ic})|u_{i1},\ldots,u_{ic}\right.\) are the characteristics of user \(u_{i}\in U\right\}\)  The \((nofu\times nofp)\) user-product matrix \(UP=\left\{\left(u_{i},\ p_{1},\ldots,p_{nofp}\right)\middle|u_{i}\in U,\ p_{1}, \ldots,p_{nofp}\in P\right\}\) Step 2: Extract \(C=\left\{c_{1},\ldots,c_{n}\right\}\) clusters of users Step 3:  For each cluster \(c_{i}\in C\) do  Form the \(|c_{i}|\times nofp\) sub user-product binary matrix \(UP_{c_{i}}=\left\{\left(u_{i},p_{1},\ldots,p_{nofp}\right)\middle|\left(u_{i },p_{1},\ldots,p_{nofp}\right)\in UP,u_{i}\in c_{i}\right\}\)  Extract frequent itemsets \(FIS_{c_{i}}=\left\{fis_{c_{i}1},\ldots,fis_{c_{i}m}\right\}\) of \(UP_{c_{i}}\)  End For  Step 4:  For each cluster \(c_{i}\in C\) do  Form the \(|c_{i}|\times nofp\) sub user-product binary matrix \(UP_{c_{i}}=\left\{\left(u_{i},p_{1},\ldots,p_{nofp}\right)\middle|\left(u_{i },p_{1},\ldots,p_{nofp}\right)\in UP,u_{i}\in c_{i}\right\}\)  Extract discriminant frequent itemsets \(DFIS_{c_{i}}=\left\{dfs_{c_{i}1},\ldots,dfs_{c_{i}q}\right\}\) of \(UP_{c_{i}}\),  where \(DFIS_{c_{i}}\subseteq FIS_{c_{i}}\) End For Step 5:  For each \(u_{i}\in U\) do  If \(\left(u_{i},\ p_{1},\ldots,p_{nofp}\right)\in UP\), \(p_{1}=p_{2}=\ldots=p_{nofp}=0\) * cold user  Then  For each \(dfs_{c_{i}k}\in DFIS_{c_{i}}\wedge u_{i}\in c_{i}\) do \(p_{s}=1,s\in fis_{c_{i}k}\)  End For  Else * sparsity  For each \(dfs_{c_{i}k}\in DFIS_{c_{i}}\wedge u_{i}\in c_{i}\) do  If \(\left|\left\{p_{s}\ \middle|\ s\in fis_{c_{i}k}\wedge p_{s}=1\right\} \right|>ct\)  If \(s\in fis_{c_{i}k}\wedge p_{s}=NULL\) Then \(p_{s}=1\) End If  End For  End If End For
```  
**Algorithm 1**Recommendation Algorithm based on Discriminant Frequent Itemsets  
The pseudo-code of the proposed methodology (Algorithm 1) along with an illustration of the corresponding steps (Figure 1) are shown in what follows. ``` Step 2: Output \(u_{1},\ldots,u_{nofp}\) \(U=\left\{u_{1},\ldots,u_{



### Input Matrices

The input to the proposed methodology is two matrices: the two-dimensional user matrix \(UM[nofu,nofuc]\) containing \(nofu\) users along with their \(nofuc\) characteristics (e.g., Table 1) and the user-product binary matrix \(UP[nofu,nofp]\) (e.g., Table 2) indicating whether a user has rated positively (value = 1) or negatively (value = 0) a product. Given that columns represent products and rows represent users, the user-product matrix may contain blank cells (e.g., in Table 2, the cell \(\left[u_{nofu},p_{3}\right]\)) indicating that the user \(u_{nofu}\) has not provided a rating for the product \(p_{3}\) (sparsity problem), as well as blank (_user_\(u_{2}\)) or almost blank rows \(\left(user\ u_{nofu-1}\right)\) (cold case problem).