## 4 Proposed HTPR Method
### Integrating Similarity Calculation and User Clustering  
In this paper, we present an integrating similarity calculation method considering user behaviors. Item category is taken as a supplement for feature input based on the result of item clustering. User behaviors can be categorized as implicit and explicit behaviors. Implicit behaviors show a user's concern for an item measured by the frequency of behaviors including browse, add-to-favorite and purchase, while explicit behavior indicates exactly a user's preference for an item, and the rating represents how much the user likes the item directly. As a matter of fact, the data size of browser behaviors is far larger than that of behaviors of add-to-favorite, and purchase. Moreover, ratings are the most valuable data with a minimum size. In order to guarantee the efficiency and quality of recommendation, data in recommendation systems are usually updated offline, for example, the short-period data (browser information) are totally updated once every day, the long-period data (information of add-to-favorite and purchase) are incrementally updated once every day, and the full-period data (rating information) are updated once every few days. According to the analysis above, preference and concern degree of a user for an item category can be defined on the basis of user behaviors and frequency of these behaviors. **Definition 2**. : _User-item category preference is defined as the ratio of the sum of ratings of a user for an item category to that of the user for all items. For example, the category preference of the user \(u\) for the item category \(E_{i},i\in[1,k_{1}]\) is represented as:_  
\[pre(u,E_{i})=\frac{\sum\limits_{i}r_{u}}{\sum\limits_{E}r_{u}},i\in[1,k_{1}]. \tag{9}\]  
User behaviors on items are endowed with weights, e.g., ratings of browse, add-to-favorite and ordering, and they are valued at 1, 3 and 5 separately. Then statistics of all items in each item category are used to count behavior frequencies and the sum of behavior ratings. A user may show a preference for a certain item category to some degree even when he/she knows little about the details. The ratio of behavior frequency of a user for an item category to that of the user for all categories is defined as RCF (relative category frequency). The ratio of the sum of behavior ratings of a user for an item category to that of the user for all categories is defined as RCR (relative category rating). The concern degree is defined as follows:  
\[conc(u,E_{i})=\frac{RCF_{u,i}\cdot RCR_{u,i}}{RCF_{u,i}+RCR_{u,i}},i\in[1,k_{1}] \tag{10}\]  
\[RCF_{u,i}=btwF_{u,i}/\emph{subhv}F_{u,i} \tag{11}\]  
\[RCR_{u,i}=btwR_{u,i}/\emph{subhv}R_{u,i} \tag{12}\]  
where \(conc(u,E_{i})\in[0,1]\) is the concern degree of the user \(u\) for the item category \(E_{i}\); \(btwFrq_{u,i}\) denotes the behavior frequency of the user \(u\) for the \(i\)-th category; \(btwR_{u,i}\) denotes the sum of behavior ratings of the user \(u\) for the \(i\)-th category. The behavior frequency and the sum of behavior ratings of the user \(u\) for all categories are respectively written as \(\emph{subhv}Frq_{u,i}\) and \(\emph{subhv}R_{u,i}\). **Definition 3**. : _User-item category tendency is an integration of preference and concern degree of a user for an item category. The tendency of the user \(u\) for the item category \(E_{i}\) is defined as follows:_  
\[ \begin{array}{c}tnd(u,E_{i})=\rho\cdot pre(u,E_{i})+(1-\partial)\cdot cnc(u, E_{i}),\\ i\in[1,k_{1}]\end{array}  \tag{13}\]  
_where \(\rho,0<\rho<1\) is a weight, called the regulating parameter._  
Once the feature vectors of user-item category tendency were obtained, a matrix could be constructed by these vectors. If the feature vector of the user \(u\) for all categories (the number is \(k_{1}\)) is denoted as \(\overset{\rightarrow}{tnd}_{u}=\left[tnd_{u,1},tnd_{u,2},\ldots,tnd_{u,k_{1}}\right]\), then the tendency matrix is \(tnd[n][k_{1}]\), \(n\) is the number of users.