## 3 Computational Approach
### Algorithm Code
It is articulated using Equation (7):

\[\text{Recall}=\frac{\text{size of hit set}}{\text{size of relevant set}}=\frac{|\text{test}\cap\text{top N}|}{|\text{test}|} \tag{7}\]

Lastly, the F-measure provides a consolidated metric derived from both precision and recall. It is the harmonic mean of the two, ensuring a balance between them. An optimal model will have both high precision and recall, leading to a high F-measure value. This is represented by Equation (8). \[F=\frac{2\times\text{Recall}\times\text{Precision}}{(\text{Recall }+\text{Precision})} \tag{8}\]

### Results

This section describes detailed experimental results of our study, performed on two real big datasets, namely Margarin and Delicious. The first part of the experiment compared tag-based weight, time-based weight, and hybrid weight methods with basic CF according to the size of the neighborhood. In the second part, the statistical significance of the recommendation improvement was verified. #### 4.3.1 Results of Margarin

The following experiments investigate the effect of neighborhood size and the parameter \(\lambda\), which determines the proportions of tag and time used to construct the hybrid weight. In the research, the neighborhood size played a pivotal role in influencing the model's performance. The neighborhood size, denoted by 'k', refers to the number of nearest users or items considered when making a recommendation. The team experimented with various neighborhood sizes, starting from a small group of three and increasing in increments of three, up to a maximum size of thirty. The results, as visualized through plots, underscored that the choice of 'k' had a considerable impact on the efficacy of the recommendations. Different sizes of 'k' might be more suitable for various datasets or user scenarios, and pinpointing the optimal value is crucial for enhancing recommendation accuracy and relevance. As k increases, the performance improves, although the rate of metric increase diminishes beyond a certain threshold. The optimal \(\lambda\) value was found by examining the highest performance of the hybrid weight across all three metrics. The study adjusted the \(\lambda\) value in steps of 0.1, ranging from 0 to 1. For the Margarin dataset, across all three evaluation criteria, a \(\lambda\) value of 0.6 emerged as the most optimal. The hybrid weight's efficacy surpassed that of weights relying on just a single element, specifically when \(\lambda\) was set to 0 for the time-based weight and \(\lambda\) was set to 1 for the tag-based weight. Figure 1 displays the precision values compared to the basic CF across various neighborhood sizes. Hybrid weight and time-based weight showed higher values than basic CFoverall. Contrary to expectations, tag-based weight resulted in lower values than basic CF. This could be because existing information was unnecessarily processed when calculating the tag weight in data with a high sparseness level. On average, the hybrid weight was 0.77% higher than CF, and the time weight was 0.49% higher than basic CF. Figure 2 illustrates the recall scores in relation to various neighborhood sizes when compared to the standard CF. Hybrid weight and time weight were greater than basic CF overall. The performance of tag weight and basic CF differed according to the size of the neighborhood and showed similar values overall. Tag weight showed lower values than basic CF. On average, the hybrid weight was larger than basic CF by 13.27%, and the time weight was larger than basic CF by 11.81%. Figure 3 showcases a comparison of the F-measure results from the experiments. Hybrid weight and time weight showed better performances than basic CF. Tag-based weight and basic CF showed no difference until \(k\) was 15. However, basic CF showed better performance than tag-based weight above a \(k\) value of 15. On average, hybrid weight was greater than basic CF by 5.63%, and time-based weight was greater than basic CF by 5.14%. Figure 1: Precision comparisons for different neighborhood sizes using the Margarin dataset.