1

arXiv:1802.09728v2 [cs.IR] 28 Feb 2018

Modelling and Analysis of Temporal Preference Drifts Using A
Component-Based Factorised Latent Approach
F. ZAFARI, Swinburne University of Technology
I. MOSER, Swinburne University of Technology
T. BAARSLAG, Centrum Wiskunde & Informatica
In recommender systems, human preferences are identified by a number of individual components with
complicated interactions and properties. Recently, the dynamicity of preferences has been the focus of several
studies. The changes in user preferences can originate from substantial reasons, like personality shift, or
transient and circumstantial ones, like seasonal changes in item popularities. Disregarding these temporal drifts
in modelling user preferences can result in unhelpful recommendations. Moreover, different temporal patterns
can be associated with various preference domains, and preference components and their combinations. These
components comprise preferences over features, preferences over feature values, conditional dependencies
between features, socially-influenced preferences, and bias. For example, in the movies domain, the user can
change his rating behaviour (bias shift), her preference for genre over language (feature preference shift), or
start favouring drama over comedy (feature value preference shift). In this paper, we first propose a novel
latent factor model to capture the domain-dependent component-specific temporal patterns in preferences.
The component-based approach followed in modelling the aspects of preferences and their temporal effects
enables us to arbitrarily switch components on and off. We evaluate the proposed method on three popular
recommendation datasets and show that it significantly outperforms the most accurate state-of-the-art static
models. The experiments also demonstrate the greater robustness and stability of the proposed dynamic
model in comparison with the most successful models to date. We also analyse the temporal behaviour of
different preference components and their combinations and show that the dynamic behaviour of preference
components is highly dependent on the preference dataset and domain. Therefore, the results also highlight the
importance of modelling temporal effects but also underline the advantages of a component-based architecture
that is better suited to capture domain-specific balances in the contributions of the aspects.
Additional Key Words and Phrases: Latent Factor Models, Bias, Feature Preferences, Feature Value Preferences,
Temporal Dynamics, Preference Drift
ACM Reference format:
F. Zafari, I. Moser, and T. Baarslag. 2018. Modelling and Analysis of Temporal Preference Drifts Using A
Component-Based Factorised Latent Approach. arXiv 1, 1, Article 1 (February 2018), 38 pages.
DOI: 0000001.0000001

1

INTRODUCTION

Recommender systems suggest items (movies, books, music, news, services, etc.) that appear
most likely to interest a particular user. Matching users with the most desirable items helps
enhance user satisfaction and loyalty. Therefore, many e-commerce leaders such as Amazon
and Netflix have made recommender systems a salient part of their services [15]. Currently,
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee
provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and
the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored.
Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires
prior specific permission and/or a fee. Request permissions from permissions@acm.org.
© 2018 ACM. 1533-5399/2018/2-ART1 $15.00
DOI: 0000001.0000001
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:2

Zafari et al.

most recommendation techniques leverage user-provided feedback data to infer user preferences
[4]. Typically, recommender systems are based on collaborative filtering (CF) [1, 14], where the
preferences of a user are predicted by collecting rating information from other similar users or
items [22]. Many recent studies have contributed extensions to the basic Probabilistic Matrix
Factorisation (PMF) by incorporating additional information. Despite their popularity and good
accuracy, recommender systems based on latent factor models encounter some important problems
in practical applications [31]. In these models, it is assumed that all values for item features are
equally preferred by all users.
Another major problem with latent factor models based on matrix factorisation is that they do not
usually take conditional preferences into consideration [19]. Furthermore, in general, latent factor
models do not consider the effect of social relationships on user preferences, which encompasses
peer selection (homophily) and social influence [17, 30]. In previous work, we addressed the
problem of modelling the socially-influenced conditional feature value preferences, and proposed
CondTrustFVSVD [32].
Since data usually changes over time, the models should continuously update to reflect the
present state of data [13]. A major problem with the most of the recent recommender systems is
that they mostly ignore the drifting nature of preferences [32]. Modelling the time drifting data
is a central problem in data mining. Drifting preferences can be considered a particular type of
concept drift, which has received much attention from researchers in recent years [27]. However,
very few recommendation models have considered the drifting nature of preferences [3]. Changes
in user preferences can originate from substantial reasons, or transient and circumstantial ones. For
example, the items can undergo seasonal changes or some items may experience periodic changes,
for instance, become popular in the specific holidays.
Apart from the short-term changes, user preferences are also subject to long term drifts. For
example, a user may be a fan of romantic or action movies at a younger age, while his/her preference
may shift more towards drama movies as gets older. Also, users may change their rating scale over
time. For example, a user may be very strict and give 3 out of 5 for the best movie. However, might
become less strict with age and be more willing to elect the full rate when fully satisfied. A similar
situation may apply for movies. A movie may receive a generally high/low rate at some time period,
and lower/higher rates at some other period [13]. Therefore, a preference model should be able to
distinguish between different types of preference drifting, and model them individually in order to
achieve the highest accuracy.
In recommender systems research, six major aspects to the preferences have been identified.
These aspects include feature preferences ([26, 36]), feature value preferences ([34, 35, 37]), sociallyinfluenced preferences ([9, 22, 23, 32, 38]), temporal dynamics ([13]), conditional preferences ([19]),
and user and item biases ([14]). Feature value preferences refer to the relative favourability of each
one of the item feature values, social influence describes the influence of social relationships on the
preferences of a user, temporal dynamics means the drift of the preferences over time, conditional
preferences refer to the dependencies between item features and their values, and user and item
biases pertain to the systematic tendencies for some users to give higher ratings than others, and
for some items to receive higher ratings than others ([14]). Modelling the temporal properties of
these preference aspects is the central theme of this paper.
In this paper, we extend our previous work [32], by considering the drifting nature of preferences
and their constituting aspects. We assume that the socially-influenced preferences over features
and conditional preferences over feature values, as well as user and item rating scales can be subject
to temporal drift. Therefore, the two major research questions addressed in this paper are:

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:3

• How can we efficiently model the drifting behaviour preferences, and how much improvement would incorporating such information make?
• Which aspects are more subject temporal changes, and how is this related to the domain
on which the model is trained?
The current work proposes a novel latent factor model based on matrix factorisation to address
these two questions. This paper has two major contributions for the field. In this paper, we make
further improvements on the accuracy of, CondTrustFVSVD, a model that we proposed earlier.
CondTrustFVSVD proved to be the the most accurate model among a large set of state of the
art models. The additional improvements were achieved by incorporating the temporal dynamics
of preference aspects. We also draw conclusions about the dynamicity of preference aspects, by
analysing the temporal aspects of the these aspects using a component-based approach, and show
which aspects are more subject to drift over time. This research provides useful insights into the
accurate modelling of preferences and their temporal properties, and helps pave the way for boosting
the performance of recommender systems. The findings suggest that the temporal aspects of user
preferences can vary from one domain to another. Therefore, modelling domain-dependent temporal
effects of preference aspects are critical in improving the quality of recommendations.
The rest of the paper is organised as follows: The related work is introduced in section 2. In
section 3.1, we first briefly introduce probabilistic matrix factorisation, and CondTrustFVSVD. Then
in section 3.2 we introduce Aspect-MF to overcome the challenge of learning drifting conditional
socially-influenced preferences over feature values. In section 4, we first explain the experimental
setup, and then report on the results of Aspect-MF using two popular recommendation datasets.
Finally we conclude the paper in section 5, by summarising the main findings and giving the future
directions of this work.
2

RELATED WORK

Collaborative Filtering models are broadly classified into memory-based and model-based approaches. Memory- or instance-based learning methods predict the user preferences based on the
preferences of other users or the similarity of the items. Item-based approaches in memory-based
CF D’Addio and Manzato [5] calculate the similarity between the items, and recommend the items
similar to the items that the user has liked in the past. User-based approaches recommend items
that have been liked by similar users Ma et al. [22]. The time-dependent collaborative filtering
models are also classified into the memory-based time-aware recommenders and model-based
time-aware recommenders [28].
2.1

Model-based time-aware recommenders

The models in this category usually fall into four classes: 1) models based on Probabilistic Matrix
Factorisation, 2) models based on Bayesian Probabilistic Matrix Factorisation, and 3) models based
on Bayesian Probabilistic Tensor Factorisation, and 4) models based on Bayesian Probabilistic
Tensor Factorisation.
2.1.1 Models based on probabilistic matrix factorisation. Modelling the drifting preferences
using a model-based approach based on PMF has first been considered by Koren [13] in TimeSVD++.
TimeSVD++ builds on the previous model called SVD++ [15], in which the user preferences are
modelled through a latent factor model that incorporates the user bias, item bias, and also the
implicit feedback given by the users. For each one of these preference aspects, Koren [13] used a
time-dependent factor to capture both transient and long-term shifts. They showed TrustSVD++
achieves significant improvements over SVD++ on a daily granularity [28].
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:4

Zafari et al.

In TrustFVSVD [32], we extended TrustSVD by adding the preferences over feature values and
the conditional dependencies between the features. We did this by adding additional matrices
that captured the feature value discrepancies, where the values of these matrices were related
to the values of the social influence matrix. In TrustFVSVD, the explicit influence of the social
relationships on each one of the aspects of preferences were captured. Through comprehensive
experiments on three benchmark datasets, we showed that TrustFVSVD significantly outperformed
TrustSVD and a large set of state of the art models. However, similar to most of the state of the art
models, in TrustFVSVD, we assumed that the preferences are static.
Another model-based time-aware recommendation model was proposed by Koenigstein, Dror
and Koren [11]. In this model, the authors use session factors to model specific user behaviour
in music learning sessions. Unlike TimeSVD++ which is domain-independent, was developed
especially for the music domain. First, it enhances the bias values in SVD++, by letting the item
biases share components for items linked by the taxonomy. For example, the tracks in a good
album may all be rated higher than the average, or a popular artist may receive higher ratings than
the the average for items. Therefore, shared bias parameters are added to different items with a
common ancestor in the taxonomy hierarchy of the items. Similarly, the users may also tend to rate
artists or genres higher than songs. Therefore, the user bias is also enhanced by adding the type
of the items. It is also assumed that unlike in the movies domain, in music it is common for the
users to listen to many songs, and rate them consecutively. Such ratings might be rated similarly
due to many psychological phenomena. The advantage of the models proposed by Koenigstein,
Dror and Koren [11] and Koren [13] that extend SVD++ is that they enable the capturing of
dynamicity of the preference aspects with a high granularity for aspects that are assumed to be
more subject to temporal drift. Furthermore, as shown in [11], domain-dependent temporal aspects
of the preferences and their individual aspects can also be taken into consideration.
Jahrer, Toscher and Legenstein [8] split the rating matrix into several matrices, called bins, based
on their time stamps. For each bin, a separate time-unaware model is trained by producing an
estimated rating value that is obtained using the ratings of given for that bin. Each one of the bins
are assigned a weight value, and the final rating is obtained by combining the ratings that are
obtained through the models trained on each bin. Therefore, using this approach, they combine
multiple time-unaware models into a single time-aware model. The disadvantage of this model is
that the ratings matrix is usually sparse as it is, and it even becomes sparser, when the ratings are
split into bins.
A similar approach is followed in the model proposed by Liu and Aberer [20]. They systematically
integrated contextual information and social network information into a matrix factorization model
to improve the recommendations. To overcome the sparsity problem of training separate models
based on their time-stamps, they applied a random decision trees algorithm, and create a hierarchy
of the time-stamps. For example, the ratings can be split based on year in the first level, month
in the second level, day in the third level, and so on. They argue that the ratings that are given at
similar time intervals are better correlated with each other, and therefore such clustering is justified.
They also added the influence of the social friends to the model, using a context-aware similarity
function. In this function users who give similar ratings to those of their friends in similar contexts
get higher similarity values. Consequently, in this model, the role of time on the social influence is
also indirectly taken into consideration.
Baltrunas, Ludwig and Ricci [2] argued that methods based on tensor factorisation can improve
the accuracy when the datasets are large. Tensor factorisation requires the addition of a large
number of model parameters that must be learned. When the datasets are small, simpler models
with fewer parameters can perform equally well or better. In their method, a matrix is added
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:5

to capture the influence of contextual factors (e.g. time) on the user preferences by modelling
the interaction of contextual conditions with the items. Although the model is quite simple and
fast, it does not include the effect of time on individual preference aspect. Unlike the models
proposed by Koenigstein, Dror and Koren [11] and Koren [13], it can not capture fine-grained and
domain-specific dynamicities.
2.1.2 Models based on Bayesian probabilistic matrix factorisation. BPMF extends the basic
matrix factorisation [25] by assuming Gaussian-Wishart priors on the user and item regularisation
parameters and letting the hyper-parameters be trained along with the model parameters. Dynamic
BPMF (dBPMF) is a non-parametric Bayesian dynamic relational data modelling approach based on
the Bayesian probabilistic matrix [21]. This model imposes a dynamic hierarchical Dirichlet process
(dHDP) prior over the space of probabilistic matrix factorisation models to capture the time-evolving
statistical properties of modelled sequential relational datasets. The dHDP was developed to model
the time-evolving statistical properties of sequential datasets, by linking the statistical properties of
data collected at consecutive time points via a random parameter that controls their probabilistic
similarity.
2.1.3 Models based on probabilistic tensor factorisation. In tensor factorisation methods,
the context variables are modelled in the same way as the users and items are modelled in matrix
factorisation techniques, by considering the interaction between users-items-context. In tensor
factorisation methods, the three dimensional user-item-context ratings are factorised into three
matrices, a user-specific matrix, an item-specific matrix, and a context-specific matrix. A model
in this category is proposed by Karatzoglou et al. [10], who used Tensor Factorisation with CPdecomposition, and proposed multi-verse recommendation, which combines the data pertaining
to different contexts into a unified model. Therefore, similar to the model proposed by Baltrunas,
Ludwig and Ricci [2], other contextual information besides time (e.g. user mode, companionship) can
also be taken into consideration. However, unlike Baltrunas, Ludwig and Ricci [2], they factorise the
rating tensor into four matrices, a user-specific matrix, an item-specific matrix, a context-specific
matrix, and a central tensor, which captures the interactions between each user, item, and context
value. Then the original ratings tensor, which includes the ratings given by users to items in
different contexts (e.g. different times) can be reconstructed by combining the four matrices back
into the ratings tensor. Other models in this category are the models proposed by Li et al. [18] and
Pan et al. [24].
2.1.4 Models based on Bayesian probabilistic tensor factorisation. There is a class of
dynamic models that are based on Bayesian Probabilistic Tensor Factorisation (BPTF) [29]. BPTF
generalises BPMF by adding tensors to the matrix factorisation process. A tensor extends the two
dimensions of the matrix factorisation model to three or more dimensions. Therefore, besides
capturing the user-specific and item-specific latent matrices, this model also trains a time-specific
latent matrix, which captures the latent feature values in different time periods. The models based
on tensor factorisation are similar in introduction of the time-specific matrices into the factorisation
process. However, they are different in the way they factorise the ratings matrix into the user, item,
and time matrices, and also the way they train the factorised matrices. Similar to BPMF, BPTF uses
Markov Chain Monte Carlo with Gibbs sampling to train the factorised matrices.
2.2

Memory-based time-aware recommenders

Some simple time-dependent collaborative filtering models have been proposed by Lee, Park and
Park [16]. The models use item-based and user-based collaborative filtering, and exploit a pseudorating matrix, instead of the real rating matrix. In the pseudo-rating matrix the entries are obtained
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:6

Zafari et al.

using a rating function, which is defined as the rating value when an item with launch time l j was
purchased at time pi . This function was inspired by two observations, that more recent purchases
better reflected a user’s current preferences, and also recently launched items appealed more to the
users. If the users are more sensitive to the item’s launch time, the function gives more weight to
new items, and if the user’s purchase time is more important in estimating their current preference,
the function assigns more weight to recent purchases. After obtaining the pseudo-rating matrix,
the neighbours are obtained as in the traditional item-based or user-based approaches, and the
items are recommended to the users. These models are less related to the proposed model in this
paper, so we are not going to review them further.
3

MODELLING TIME-AWARE PREFERENCE ASPECTS IN CONDTRUSTFVSVD

In this section, we explain how to integrate the time-awareness on different aspects of preferences
into CondTrustFVSVD [32].
3.1

Brief introduction of PMF and CondTrustFVSVD

In rating-based recommender systems, the observed ratings are represented by the user-item ratings
matrix R, in which the element Ru j is the rating given by the user u to the item j. Usually, Ru j is a
5-point integer, 1 point means very bad, and 5 points means excellent. Let P ∈ RN ×D and Q ∈ RM ×D
be latent user and item feature matrices, with vectors Pu and Q j representing user-specific and
item-specific latent feature vectors respectively (N is the number of users, M is the number of
items, and D is the number of item features). In PMF, Ru j is estimated by the inner product of the
latent user feature vector Pu and latent item feature vector Q j , that is R̂u j = Pu Q Tj .
PMF maximises the log-posterior over the user and item latent feature matrices with rating
matrix and fixed parameters given by Eq. 1.
ln p( P, Q |R, σ , σP , σQ ) = ln p( R|P, Q, σ ) + ln p( P |σP ) + ln p( Q |σQ ) + C

(1)

where C is a constant that is not dependent on P and Q. σP , σQ , and σ are standard deviations
of matrix entries in P, Q, and R respectively. Maximising the log-posterior probability in Eq. 1 is
equivalent to minimising the error function in Eq. 2.
arдminU ,V [ E =

N M
N
M
λQ Õ
1 ÕÕ
λP Õ
Iu j ( Ru j − R̂u j ) 2 +
kPu kF2 r ob +
kQ j kF2 r ob ]
2 u=1 j=1
2 u=1
2 j=1

where k.kF r ob denotes the Frobenius norm, and λ P =

σ2
σ P2

and λQ =

σ2
2
σQ

(2)

(regularisation parame-

ters). Stochastic Gradient Descent and Alternatinд Least Squares are usually employed to solve
the optimisation problem in Eq. 2. Using these methods, the accuracy of the method measured on
the training set is improved iteratively.
As mentioned in the introduction section, the disadvantage of traditional matrix factorisation
methods is that the discrepancies between users in preferring item feature values and conditional
dependencies between features are disregarded. CondTrustFVSVD [32] addresses these problems
by adding matrices W and Z to learn the preferences over item feature values. Suppose that a
social network is represented by a graph G = (V, E), where V includes a set of users (nodes) and
E represents the trust relationships among the users (edges). We denote the adjacency matrix by
T ∈ RN ×N , where Tuv shows the degree to which user u trusts user v. Throughout this paper, we
0
use the indices u and v for the users and indices i and j for items, and indices f and f for item
features. In CondTrustFVSVD, all aspects of preferences are assumed to be subject to change by
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:7

social interactions, and therefore the explicit influence of social relationships on each of the aspects
of the preferences are modelled. In this method, we assume that the user preferences over an item
feature can be formulated with a linear function. In this function, matrix W is used to capture the
"gradient" values and matrix Z is used to learn the "intercept" values. These matrices have the same
dimensions as the user matrix P. According to this figure, the probabilities of the matrices P, Q, W ,
Z , ω, y and vectors bu and bi are dependent on the hyper-parameters σP , σQ , σW , σZ , σω , σy , σbu
and σbi respectively. Likewise, the probability of obtaining the ratings in matrix R is conditional
upon the matrices P, Q, W , Z , ω, y and vectors bu and bi. CondTrustFVSVD finds the solution for
the optimisation problem formulated by Eq. 3.
arдmin P,Q,W ,Z,ω,y,bu,bi [ E =

D
D
N
N
Õ
Õ
λt Õ Õ
λt Õ Õ
Iuv (Tuv −
Puf ωv f ) 2 +
(Tuv −
(1 − Wuf )ωv f ) 2
2 u=1
2 u=1
∀v ∈Tu
∀v ∈Tu
f =1
f =1

+

N
N M
D
Õ
λt Õ Õ
1 ÕÕ
(Tuv −
Zuf ωv f ) 2 +
( Ru j − R̂u j ) 2
2 u=1
2 u=1 j=1
∀v ∈Tu
f =1

+

N
M
Õ
λQ Õ
1
1
λP
λT
( |Iu | − 2 +
kQ j kF2 r ob
|Tu | − 2 )kPu kF2 r ob +
2
2
2 j=1
u=1

N
N
Õ
Õ
1
1
1
1
λW
λT
λZ
λT
(
|Iu | − 2 +
|Tu | − 2 )kWu kF2 r ob +
( |Iu | − 2 +
|Tu | − 2 )kZu kF2 r ob
2
2
2
2
u=1
u=1
M
N
Õ
Õ
1
1
λω
λ
|Ui | − 2 kyi kF2 r ob +
|T + | − 2 kωv kF2 r ob
+
2 i=1
2 v=1 v

+

N
M
D D
1
1
λ Õ
λ Õ
λY Õ Õ 2
|Iu | − 2 buu2 + bi
|U j | − 2 bi 2j +
+ bu
Y 0]
ff
2 u=1
2 j=1
2
f =1 f 0 =1

(3)

where λW =

σ2
2
σW

, λZ =

σ2
σZ2

, λω =

σ2
σω2

, λy =

σ2
,
σy2

λbu =

σ2
2
σbu

, λbi =

σ2
2
σbi

, λY =

σ2
σY2

. µ denotes

the global average of the observed ratings, and bui and bi j denote biases for user i and item j
respectively. Iu is the set of items rated by user u and U j is the set of users who have rated item j.
The values of R̂u j in Eq. 3 are obtained using Eq. 4.

R̂u j = µ + buu + bi j +

D
Õ
f =1

1

(Puf + |Iu | − 2

Õ

1

yif + |Tu | − 2

∀i ∈Iu

Õ

ωv f )(Wuf Q jf + Zuf )

(4)

∀v ∈Tu

According to the Eq. 4, the user u’s preference value over an item j is defined using different
aspects. These aspects are user bias, item bias, the socially-influenced preferences over features, and the socially-influenced preferences over feature values. Therefore, preferences
are defined using different aspects that interact with each other by influencing the values of one
another.
3.2

Time-aware CondTrustFVSVD (Aspect-MF)

In the following sections, we first provide a high-level view of Aspect-MF by explaining the
interactions between aspects that are captured by the model, and then elaborating how the aspects
are trained from the users’ ratings and social relationships.
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:8

Zafari et al.

3.2.1 Aspect interactions and high-level view of the model. To address the problem of
capturing drifting socially-influenced conditional preferences over feature values, we extend the
method CondTrustFVSVD, by adding the dynamicity of each one of the preference aspects that are
assumed to be subject to concept drift. The method proposed here is abbreviated to Aspect-MF. A
high-level overview of the preference aspects in Aspect-MF are presented in Fig. 1.

Fig. 1. The preference aspects and their interplay in Aspect-MF

In Fig. 2a, FP represents preferences over features, which is captured by matrix P in the basic
matrix factorisation. F represents item features captured by matrix Q in the basic matrix factorisation.
CP represents conditional dependencies, FVP represents preferences over feature values, SI stands
for social influence, and finally T is an abbreviation for time. Aspect-MF incorporates additional
matrices and vectors into matrix factorisation to capture as many aspects present in the data
as possible. As Fig. 2 shows, the model starts by loading the time-stamped user ratings as well
as the social network data into the memory. The main loop accounts for the learning iterations
over the model. The first loop within the main loop iterates over the time-stamped user-item
ratings matrix, while the second loop iterates over the social network adjacency matrix, to train
the socially influenced parts of the model. In each loop, one entry of the input matrix is read and
used to update the matrices/vectors related to that input data. As can be seen, the user and item
bias values are only updated in loop 1, since they are only related to the user-item ratings. Both
user-item ratings and users’ social relationships include information about the users’ preferences
over features. Therefore, the new values for FP are calculated in both loops and updated in the
main loop, when all new values have been calculated. Similarly, the values for SI and FVP depend
on both user-item ratings and social relationships. Consequently, their new values are calculated
inside both loops 1 and 2, and are updated in the main loop. In contrast, the values of F as well as
CP only need the user-item ratings to be updated. Therefore, they are immediately updated inside
loop 1. The time aspect includes parameters that account for the dynamics of user and item biases,
feature value preferences, and preferences over features. Since bias values do not depend on the
user-item ratings matrix, they are updated immediately in loop 1. However, the new values for
the dynamics of feature value preferences, and preferences over features are updated in the main
loop. In Aspect-MF, every one of the preference aspects can be arbitrarily switched off and on by
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:9

Start

Load Social
Network Data

Load Time-Stamped
Ratings Data

Initial User and Item Models
User Model

Initialise FP
Matrix

Initialise B
Vectors

Item Model

Initialise
FVP
Matrices

Initialise CP
Matrix

Initialise SI
Matrix

Initialise T
Matrices and
Vectors

Initialise F
Matrix

Iteration = 1

Iteration < Max Iteration
Yes

Read a Rating Value
and the Associated
Time Stamp

Read a Social
Trust Value

Loop 1

Loop 2
All Values
Read?

Yes

Yes

No

All Values
Read?
Iteration++

No

- Update User and Item Bias Values
- Update F Item Vector
- Calculate Next FP User Vector
- Calculate Next FVP User Vector
- Calculate Next SI User Vector
- Update CP Feature Vector
- Update Time-Bias Vectors
- Estimate Next Time-FP User Vector
- Estimate Next Time-FVP User Vector

No

- Calculate Next FP User Vector
- Calculate Next FVP User Vector
- Calculate Next SI User Vector
- Estimate Next Time-FP User Vector
- Estimate Next Time-FVP User Vector

- Update FP User Vectors
- Update FVP User Vectors
- Update Time-FP User Vector
- Update Time-FVP User Vector

Extracted
Preference Model

Finish

(a)

(b)

Fig. 2. a) The high-level representation of Aspect-MF and b) its flow chart

setting their respective learning rates and regularisation parameters (hyper-parameters) to zero or
a non-zero value respectively.
Although social relationships are likely to be time-dependent, most datasets do not contain
this information. Conditional preferences are related to the feature value preferences, since they
model the dependencies between the features and their values, and therefore, are applied to the
matrices that account for the users’ preferences over feature values. Social influence is applied to
the aspects of preferences over features and preferences over feature values. However, applying
social influence to the user and item biases showed no observable benefits and user or item biases
do not seem to be influenced by social interactions. Therefore, we concluded that user and item
biases are not much influenced by the social interactions [32]. Therefore, in the most abstract
view of the model as depicted in the high-level representation in Fig. 2a, the model is comprised
of four main modules. Initialising the model parameters (Model Initialiser), learning the intrinsic
constituting aspects of preferences (i.e. preferences over features, preferences over feature values,
conditional dependencies, and user and item bias values) and the drifting properties of preferences
(Intrinsic Trainer), learning the social influence of the friends over the drifting intrinsic preference
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:10

Zafari et al.

aspects (Social Trainer), and finally updating the model to reflect the new information extracted
from the data about user ratings, time, and social connections (Model Updater). These modules will
be discussed in more details later, when we introduce the algorithm in section 3.2.4.
3.2.2 Aspect-MF model formulation. In this section, we provide the mathematical formulation of the preferences captured in Aspect-MF. Basically, in Aspect-MF, the user preferences are
modelled as a Bayesian Network [12]. Fig. 3 shows the topology or the structure of the Bayesian
Network for user preferences that are modelled by Aspect-MF.
As mentioned earlier, Aspect-MF extends CondTrustFVSVD, by adding the time factor to the
aspects of preferences as depicted in Fig 1. In CondTrustFVSVD, the user preferences were captured
using the matrices P, Q, W , Z , Y , ω, y, with the hyper-parameters σP , σQ , σW , σZ , σω , σy , σY , σbu
and σbi .
Aspect-MF
f=1,…,D

σY

Yf

σT

v=1,…,N
Ttuv

Stuv

Gtuv
σQ
αZ
Ztut

σZ

Zu
αW
yj

Qj

σαZ
σZt

σαW
σWt

Wtut

σW
σαP

Wu
αP

σPt

Ptut

σP

Ptu

σω

ωu

Ruj
u=1,…,N
σ

Cu

Ctut

Buu

Butut

α

σCu

σCt

σbu

σbut

σα

j=1,…,M

u=1,…,N

Bitjt

Bij

j=1,…,M
σbit

σbi

Fig. 3. Bayesian network of Aspect-MF

In Aspect-MF, the drifting social influence of friends in the user’s social network are captured
through Eq. 5 to 7.
t
T̂uv
=

D
D
1 Õ Õ
Puf (tu j )ωv f
|Iut |
t f =1

(5)

∀tu j ∈Iu

D
D
1 Õ Õ
t
Sˆuv
= t
(1 − Wuf (tu j ))ωv f
|Iu |
t f =1
∀tu j ∈Iu

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

(6)

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

t
Ĝuv
=

D
D
1 Õ Õ
Zuf (tu j )ωv f
|Iut |
t f =1

1:11

(7)

∀tu j ∈Iu

t , Sˆt , Ĝ t model the time-dependent influence of user v on the preferences of user u
where T̂uv
uv
uv
for the preferences over features (captured by Puf (t)) and preferences over feature values (captured
by Wuf (t) and Zuf (t)), and similar to CondTrustFVSVD, ω captures the implicit influence of user
u on other users and is obtained using the matrix factorisation process. As can be seen in Fig. 1,
the user preferences over features and feature values in Aspect-MF are subject to social influence,
and they also drift over time. In Eqs. 5 to 7, Iut is the set of timestamps for all the ratings given by
user u. Therefore, using these equations, the influence of the user v on the preferences of user u is
calculated for all the time points, and then it is averaged. Intuitively, these equations are telling
us that the trust of user u in user v can be estimated by calculating the average of the weighted
averages of user v’s influence on user u’s preferences for different features, in different times.
Intuitively, if user u strongly trusts user v, his preferences would be more strongly influenced
by user v. Furthermore, depending on the trust strength of user u in user v and the influence he
gets from user v and its direction (positive or negative), the user’s preference can be positively or
negatively affected. Therefore in Aspect-MF, the user preferences are subject to social influence,
and the social influence depends on the strength of their trust in the friends. According to these
equations, if there is no relationship between user u and user v, user u’s preferences will not be
directly affected by the social influence of user v.
In Aspect-MF, the drifting preference value of the user u over an item j at time t is obtained
according to Eq. 8.

R̂u j (tu j ) = µ + buu (tu j ) + bi j (tu j )
+

D
Õ
Õ
Õ
1
1
yif + |Tu | − 2
ωv f )(Wuf (tu j )Q jf + Zuf (tu j ))
(Puf (tu j ) + |Iu | − 2
f =1

+

D
Õ

∀i ∈Iu

(

∀v ∈Tu

(8)

D
Õ

(Wuf (tu j )Q jf + Zuf (tu j ))Yf f 0 )(Wuf (tu j )Q jf 0 + Zuf (tu j ))

f =1 f =1
0

According to Eq. 8, in Aspect-MF, different aspects of preferences as well as user and item biases
are subject to temporal drift. As can be seen in Eq. 5 to 8, the user bias, item bias, preferences over
features captured by the matrix P, and preferences over feature values captured by the matrices W
and Z are subject to temporal drift. In order to model the drifting properties of these aspects, we
use Eqs. 9 to 13.
buu (tu j ) = buu + αu devu (tu j ) + bututu j

(9)

bi j (tu j ) = (bi j + bi j Bin(tu j ) )(Cu + Ctutu j )

(10)

Puf (tu j ) = Puf + αuP devu (tu j ) + Ptuf tu j

(11)

Zuf (tu j ) = Zuf + αuZ devu (tu j ) + Ztuf tu j

(12)

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:12

Zafari et al.

Wuf (tu j ) = Wuf + αuW devu (tu j ) + W tuf tu j

(13)

where Puf , Wuf , and Zuf capture the static preferences of the user u, while the variables Puf tu j ,
Wuf tu j , Zuf tu j capture the day-specific variations in the user preferences (e.g. due to the mood of
the users in a particular day), and αuP , αuW , and αuZ model the users’ long term preference shifts,
and devu (tu j ) is obtained according to Eq. 14 [13].
devu (tu j ) = siдn(tuu j − tu ).|tu j − tu | β

(14)

where tu is the mean of the dates for the ratings given by the user u, and β is a constant value.
In Eq. 10, all the dates are placed in a fixed number of bins, and the function Bin(.) returns the bin
number for a particular date. For example, if the maximum period of the ratings is 30 years and 30
bins are used, all the rates given in a particular year are placed in a bin, and the function Bin(.)
returns the year number for that particular year. The reason why this function is only used for items
is that items are not expected to change on a daily basis, and as opposed to users’ biases, longer
time periods are expected to pass, before we see any changes in the items’ popularity. In simple
words, devu (tu j ) shows how much the time of the rating given by user u to the item j deviates from
the average time of the ratings given by that user. Therefore, if a rating is given at the same time as
the average time of the ratings, then the according to these equations, there will be no long-term
preference shift for that aspect. However, for instance, if the average time of the rates given by
user u is 11/04/2006, the rating of the same item by that user on 11/04/2016 would be different, and
this shift is captured by the coefficients of the function devu (tu j ) in Eq. 9 and Eqs. 11 to 13. The
drifting preferences captured using Eq. 9 and Eqs. 11 to 13 are depicted in Fig. 4. In these figures,
the mean of the dates on which the user has given the ratings are assumed to be 50 (the fiftieth
day in a year), and the variations of the user preferences over a period of one year are captured for
different values of α in Eq. 9 and Eqs. 11 to 13. The red lines in these figures represent the case in
which the day-specific variations in the user preferences are not captured, while the blue lines also
include the day-specific variations. Therefore, as can be seen, in these figures there are two types
of preference shifts, long term drifts (captured by the values of α, α P , α W , and α Z ), and short-term
or day-specific drifts (captured by the values of but, Pt, W t, and Zt). Therefore, the preference
drifts are comprised of small variations from one day to the other, mainly because of temporary
factors such as the mood of the user, and the large variations which happen in the long term, as
the user changes preferences because of the shift in the his/her tastes. The blue lines show the
preference shift patterns that can be learnt by Aspect-MF. Furthermore, the first three terms in Eq.
18 model the social influence of the feature preferences and feature value preferences captured by
P, α P , Pt, W , α W , W t, Z , α Z , Zt. Therefore, assuming that two users have established the social
relationship from the very beginning (which is not essentially true, but usually social relationships
do not contain time-stamps), using the Eqs. 5 to 7, the social influence is applied to the preferences
of the user over the entire period for which the rating data is record. Therefore, the formulation
of the estimated ratings in Aspect-MF (8) allows it to learn the drifting conditional feature value
preferences, and the formulation of the optimisation in Aspect-MF (Eq. 18) enables it to learn the
influence of social friends on the drifting preferences of a user.
Eqs. 9 to 13 show how Aspect-MF can capture long-term and short-term drifts in each one of the
preference aspects (user bias, item bias, feature preferences, and feature value preferences). The
advantage of formulating the problem using Eq. 8 is that each one these aspects can be arbitrarily
switched on/off. This results in a component-based approach, in which the model aspects interact
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach
α = 0.2

α = 0.4

6
Matrix Entry Value

Matrix Entry Value

4
3
2
1
0

With day-spefiic variations
Without day-specifc variations

-1

4

2

0
With day-specific variations
Without day-specific variations

-2
0

50

100

150

200

250

300

350

400

0

50

100

150

Day

200

250

300

350

400

Day

α = 0.6

8

α = 0.8

10

6

Matrix Entry Value

Matrix Entry Value

1:13

4
2
0
With day-specific variations
Without day-specific variations

-2
-4

8
6
4
2
0
With day-specific variations
Without day-specific variations

-2
-4

0

50

100

150

200

250

300

350

400

0

50

100

150

200

250

300

350

400

Day

Day

(a)
α = -0.2

2.5

Matrix Entry Value

Matrix Entry Value

With day-specific variation
Without day-specific variation

3

1.5
1
0.5
0
-0.5
-1

2
1
0
-1
-2
-3

-1.5

-4
0

50

100

150

200

Day

250

300

350

400

0

α = -0.6

6

50

100

150

200

Day

250

Matrix Entry Value

0
-2
-4

350

400

With day-specific variation
Without day-specific variation

4

2

300

α = -0.8

6
With day-specific variation
Without day-specific variation

4

Matrix Entry Value

α = -0.4

4
With day-specific variation
Without day-specific variation

2

2
0
-2
-4
-6

-6

-8
0

50

100

150

200

Day

250

300

350

400

0

50

100

150

200

Day

250

300

350

400

(b)
Fig. 4. An example of drifting preferences in Eq. 9 and Eqs. 11 to 13 for a) positive α values and b)
negative α values

with each other, with the purpose of extracting as much preference patterns from the raw data as
possible.
3.2.3 Aspect-MF model training. According to the Bayesian network of Aspect-MF in Fig.
3, this model minimises the log-posterior probability of matrices that define the user preferences,
given the model hyper-parameters and the training matrix. Formally,
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:14

Zafari et al.

arдmin P, P t,α P ,Q,W ,W t,α W ,Z,Z t,α Z ,Y ,ω,y,bu,α,but,C,Ct,bi,bit
{lnp(P, Q,W , Z , ω, y, bu, bi, αu , but , bi Bin(t ) , c, c t , α P , α Z , α W , Pt , Z t ,Wt
t

t

(15)

t

|R,T , S , G , σ N }

σ N ={σ ,σT ,σP ,σP t ,σα P ,σQ ,σW ,σW t ,σα W ,σZ ,σZ t ,σα Z ,σω ,σy ,σbu ,σα ,σbut ,σC ,σCt ,σbi ,σbit ,σY }
denotes the set of all the hyper-parameters. T t , S t , G t respectively denote the real values for the
estimated matrices T̂ t , Sˆt , and Ĝ t in Eqs. 5 to 7. According to the Bayesian network in Figure 3 and by
decomposing the full joint distribution using chain rule of probability theory [12] according to the
conditional dependencies between the variables defined in this figure, minimising the probability
above is equal to minimising the value given in Eq. 16 [12].
arдmin P, P t,α P ,Q,W ,W t,α W ,Z,Z t,α Z ,Y,ω,y,bu,α,but,C,Ct,bi,bit,Y
{lnp(R|P(t), Q,W (t), Z (t), bu(t), bi(t), Y , σ ) + lnp(Q |σQ )
+ lnp(P(t)|σP ) + lnp(W (t)|σW ) + lnp(Z (t)|σZ )
+ lnp(bu(t)|σbu ) + lnp(bi(t)|σbi ) + lnp(y|, σy ) + lnp(Y |, σ)

(16)

t
t
t
+ lnp(Tuv
|ω, P(t), σT ) + lnp(Suv
|ω,W (t), σT ) + lnp(Guv
|ω, Z (t), σT )

+ lnp(P(t)|σT ) + lnp(W (t)|σT ) + lnp(Z (t)|σT ) + lnp(ω |, σT )}

Provided that all the probabilities above follow a normal distribution, it can be shown that
minimising the function in Eq. 16 is equivalent to minimising the error value using the function in
Eq. 19.

ER =

N M
M
M
λQ Õ
λy Õ
1
1 ÕÕ
( Ru j − R̂u j ) 2 +
kQ j kF2 r ob +
|Ui | − 2 kyi kF2 r ob
2 u=1 j=1
2 j=1
2 i=1

+

N
Õ
1
λP
|Iu | − 2 (kPu kF2 r ob + kPtut kF2 r ob + kα P kF2 r ob )
2
u=1

+

N
Õ
1
λW
|Iu | − 2 (kWu kF2 r ob + kW tut kF2 r ob + kα W kF2 r ob )
2
u=1

+

N
Õ
1
λZ
|Iu | − 2 (kZu kF2 r ob + kZtut kF2 r ob + kα Z kF2 r ob )
2
u=1

+

N
Õ
1
λZ
|Iu | − 2 (kZu kF2 r ob + kZtut kF2 r ob + kα Z kF2 r ob )
2
u=1

N
1
λ Õ
+ bu
|Iu | − 2 (buu2 + αu2 + Cu2 + kbuu kF2 r ob + kCtu kF2 r ob )
2 u=1
M
M
D D
1
1
λ Õ
λ Õ Õ
λY Õ Õ 2
+ bi
|U j | − 2 bi 2j + bi
|U j | − 2 bit j,2 Bin(t ) +
Y 0
ff
2 j=1
2 j=1
2
f =1 f 0 =1
∀t ∈I jt

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

(17)

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

ET =

1:15

N
N
N
λt η P Õ Õ
λt ηW Õ Õ
λt ηZ Õ Õ
(Tuv − T̂uv ) 2 +
(Tuv − Sˆuv ) 2 +
(Tuv − Ĝuv ) 2
2 u=1
2 u=1
2 u=1
∀v ∈Tu

∀v ∈Tu

∀v ∈Tu

N
Õ
1
λT
+
|Tu | − 2 (kPu kF2 r ob + kPtut kF2 r ob + kα P kF2 r ob )
2
u=1

+

N
Õ
1
λT
|Tu | − 2 (kWu kF2 r ob + kW tut kF2 r ob + kα W kF2 r ob )
2
u=1

+

N
Õ
1
λT
|Tu | − 2 (kZu kF2 r ob + kZtut kF2 r ob + kα Z kF2 r ob )
2
u=1

+

N
λω Õ + − 1
|T | 2 kωv kF2 r ob
2 v=1 v

arдmin P, P t,α P ,Q,W ,W t,α W ,Z,Z t,α Z ,Y,ω,y,bu,α,but,C,Ct,bi,bit [ E = E R + ET ]

(18)

(19)

where I jt is the set of timestamps, for all the ratings given to item j, and η P , ηW , and η Z are
constants added to control the weights of the components related to the social aspect in this
equation. The details of the model training can be found in Appendix A.
3.2.4 Aspect-MF algorithm. Algorithm 1 describes the details of the gradient descent method
Aspect-MF uses to train the model parameters (P, Pt, α P , Q, W , W t, α W , Z , Zt, α Z , Y , ω, y, bu, α,
but, C, Ct, bi, bit) as expressed in Eq. 19.
The algorithm receives the set of model hyper-parameters λ and the set of learning rates γ as
input, and trains the model parameters according to the Bayesian approach described in section
3.2.2. As we showed in the high-level representation of the algorithm in Figure 2a, the model is
comprised of four basic components. A model initialiser, which initialises the model parameters
after the input data is loaded into memory, an intrinsic trainer, which trains the model parameters
using the user-item ratings, a social trainer which trains the model parameters using the social
relationship data, and finally, a model updater, which updates the model based on the trained
parameters for a particular iteration.
As can be seen in line 11 in Algorithm 1, the training starts with initialising the model parameters.
The matrices P, Q, y, and ω and user and item bias vectors (bu and bi) are randomly initialised
using a Gaussian distribution with a mean of zero and the standard deviation of one. The new
matrices Pt, W , W t, Z , Zt, Ct, but, bit, and Y and the vectors α, α P , α W , α Z , C are initialised with
constant values. By using constant values to initialise the matrices and vectors, the algorithm starts
the search process at the same starting point as CTFVSVD, and explores the modified search space
to find more promising solutions, by considering the possible conditional dependencies between
the features and the differences between users in preferring item feature values, as well as dynamic
properties of the preferences, and the influence of social friends in the preferences of a user.
The main algorithm consists of a main loop, which implements the learning iterations of the
model. Each iteration is comprised of one model intrinsic training operation (Algorithm 3), one
model social training operation (Algorithm 4), and one model updating operation (Algorithm 5).
In the model intrinsic trainer, the model parameters are updated using the gradient values in Eqs.
26 to 66, using a rating value that is read from the user-item ratings matrix. First in line 8, the
estimated rating is calculated according to Eq. 8. Then the basic parameters of the model, P, Q,
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:16

Zafari et al.

W , Z , Y , bu, and bi, and the temporal parameters but, bit, α, C, Ct, α P , α W , α Z , Pt, W t, and Zt are
R
updated using the rating-related gradient values ( ∂E
∂(.) ) in the Eqs. 26 to 66. Since this trainer only
learns the intrinsic user preferences, only the error value in Eq. 17 will be used to update the model
parameters. After learning the intrinsic preferences, the function in Algorithm 4 is invoked to train
the social aspects of the preferences. Similar to IntrinsicTrainer, SocialTrainer is also comprised of
a main loop, which iterates over the social relationship data in the social matrix. In each iteration,
one entry from the social matrix is read, and the socially-influenced parameters of the model
are updated though the gradient values that are obtained using the error in Eq. 18. Finally, the
ModelUpdater in Algorithm 5 is invoked, and the calculated model updates are applied to the model
parameters. This process is repeated for a fixed number of iterations, or until a specific condition is
met. At the end of this process, the model parameters (P, Pt, α P , Q, W , W t, α W , Z , Zt, α Z , Y , ω, y,
bu, α, but, C, Ct, bi, bit) are trained using the input data, and can be used to estimate the rating
value given by a user u to an item j according to Eq. 8.
3.2.5 Computational complexity analysis. The model training in Algorithm 1 is comprised
of one main loop that iterates for a fixed number of iterations (maxIter). Therefore, the computation
time of the model trainer is expressed in Eq. 20.
C(ModelTrainer ) = C(IntrinsicTrainer ) + C(SocialTrainer ) + C(ModelU pdater )

(20)

First, we examine the computational complexity of Intrinsic Training in Algorithm 3. On the
highest level, this algorithm is comprised of two loops that iterate over the non-zero ratings in the
rating matrix R. In the following, |R| and |T | denote the number of non-zero entries in the rating
matrix R and adjacency matrix T respectively. In Intrinsic Trainer:
• The number of repetitions to calculate the estimated ratings (R̂) in line 8 is (D 2 × |R|) +
ÍN
ÍN
(D × u=1
|Iu | 2 ) + (D × u=1
|Iu | × |Tu |).
• The number of repetitions to update parameters related to user and item biases in lines 10,
11, and 12 is 7 × |R|.
• The number of repetitions needed to update the parameters P, Q, W , and Z in lines 15, 16,
17, and 18 is 10 × D × |R|.
ÍN
• The number of repetitions needed to update the parameters ω in line 19 is D × u=1
(|Iu | ×
|Tu |).
ÍN
• The number of repetitions needed to update the parameters y in line 20 is D × u=1
|Iu | 2 .
2
• The number of repetitions needed to update the dependency matrix Y in line 23 is D × |R|.
Therefore, the overall number of repetitions for the Intrinsic Trainer is obtained according to Eq.
21.

N (IntrinsicTrainer ) = D 2 × |R| + D ×

N
Õ

|Iu | × |Tu | + 7 × |R| + 10 × D × |R|

u=1

+D ×

N
Õ

(|Iu | × |Tu |) + D ×

u=1

N
Õ

|Iu | 2

(21)

u=1

+ D 2 × |R|

Assuming that on average, each user rates c items, and trusts k users, the computation time can
be obtained as Eq. 22.
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:17

Algorithm 1 Model Training
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:

void ModelTrainer(λ, γ , maxIter ) a
λ ={λT ,λ P ,λ P t ,λ α P ,λQ ,λW ,λW t ,λ α W ,λ Z ,λ Z t ,λ α Z ,λ ω ,λy ,λbu ,λ α ,λbut ,λC ,λCt ,λbi ,λbit ,λY }
γ ={γT ,γ P ,γ P t ,γ α P ,γQ ,γW ,γW t ,γ α W ,γ Z ,γ Z t ,γ α Z ,γ ω ,γy ,γbu ,γ α ,γbut ,γC ,γCt ,γbi ,γbit ,γY }
{
//Creating matrices P, ω, W , and Z and temporary matrices P S , ω S , W S , and Z S :
Matrix P, P S ; Matrix ω S ; Matrix W S ; Matrix Z S ;
//Creating vectors α P , α W , and α W , and temporary vectors β P , β W , and β W :
V ector α P , β P ; V ector α W , β W ; V ector α Z , β Z ;
//Creating tables Pt, W t, and Zt, and temporary tables Pt S , W t S , and Zt S :
T able Pt, Pt S ; T able W t,W t S ; T able Zt, Zt S ;
ModelInitialiser();
l ← 1;
for l  maxIter do
IntrinsicT rainer ();
SocialT rainer ();
ModelU pdater ();
error ← error × 0.5;
l ← l + 1;
}

Algorithm 2 Model Initialising
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:

void ModelInitialiser(λ, γ )
{
initMean ← 0; initStd ← 1;
P .init(initMean, initStd); α P .initConst(0); Pt .initConst(0);
P S .init(initMean, initStd); β P .initConst(0); Pt S .initConst(0);
W .initConst(0); α W .initConst(0);W t .initConst(0);
W S .init(initMean, initStd); β W .initConst(0);W t S .initConst(0);
Z .initConst(0); α Z .initConst(0); Zt .initConst(0);
Z S .init(initMean, initStd); β Z .initConst(0); Zt S .initConst(0);
ω.init(initMean, initStd); ω S .init(initMean, initStd);
bu.init(initMean, initStd); α .init(0); but .init(0); C.init(0); Ct .init(0);
bi.init(initMean, initStd); β .initConst(0); bit .initConst(0);
Q.init(initMean, initStd); y.init(initMean, initStd); b
}

a λ is the set of the model hyper-parameters as specified in Eqs. 17 and 18 and Figure 1. N , M , and D respectively denote number of users,
number of items, and number of features. γ denotes the set of learning rates, max I t er denotes the maximum number of learning iterations.
b init Mean and init Std are the mean and standard deviation values that are used to initialise the model parameters. init(initMean,
initStd) is a function that initialises a bias vector (e.g. bu and bi) and a matrix (e.g. P , and Q ) using Gaussian distribution with mean value of
init Mean and standard deviation of init Std. initConst(initMean, initStd) initialises a matrix (e.g. W and Z ) with a constant value.

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:18

Zafari et al.

Algorithm 3 Intrinsic Training
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:

void IntrinsicTrainer(λ, γ )
{
u ← 1;
for u  N do
j ← 1;
for j  M do
if Ru j , 0 then
Calculate R̂u j according to Eq. 8.
Get the time t that the rating Ru j has been given.
Update buu , butut , and αu according to Eqs. 26-28 using γ α , γbu , γbut ;
Update bi j and bit jt according to Eqs. 29-30 using γbi and γbit ;
Update Cu and Ctut according to Eqs. 31-32 using γC and γCt ;
f ← 1;
for f  D do
S , Pt S , and β P according to Eqs. 34, 37, and 40 using γ , γ , and γ ;
Update Puf
P Pt
αP
u
uf t
Update Q jf according to Eq. 65 using γQ ;
S , W t S , and β W according to Eqs. 43, 46, and 49 using γ , γ
Update Wuf
W W t , and γ α W ;
u
uf t
S
S
Z
Update Zuf , Ztuf t , and βu according to Eqs. 52, 55, and 58 using γ Z , γ Z t , and γ α Z ;
∀v ∈ Tu : Update ωvS f according to Eq. 60 using γ ω ;
∀i ∈ Iu : Update yif according to Eq. 58 using γy ;
0
f ← f + 1;
0
for f  D do
Update Yf f 0 and Yf 0 f according to Eq. 64 using γY ;
0
0
f ← f + 1;
f ← f + 1;
j ← j + 1;
u ← u + 1;
}

C(IntrinsicTrainer ) = O(D 2 × |R|) + O(D × c × |R|) + O(D × k × |T |)

(22)

Assuming that c, k ≪ N , we can ignore the values of c and k. Therefore, the computational
time of the Intrinsic Trainer would be obtained according to Eq. 23.
C(IntrinsicT rainer ) = O(D 2 × |R|) + O(D × |R|) + O(D × |T |) = O(D 2 × |R|) + O(D × |T |)

(23)

Consequently, the overall computation time is linear with respect to the number of observed
ratings as well as observed trust statements. Social Trainer consists of two loops that iterate over
the non-zero trust relations in the adjacency matrix T . The number of repetitions needed to update
the parameters P, W , Z , and β P , β W , and β Z is 6 × D × |T |. The number of repetitions to update
ÍN
the values of Pt, W t, Zt, and ω is equal to 4 × ( u=1
|Iu | × |Tu | × D). Therefore, the computation
time of Social Trainer is equal to:
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:19

Algorithm 4 Social Training
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:

void SocialTrainer(λ, γ )
{
u ← 1;
for u  N do
v ← 1;
for v  N do
if v ∈ Tu then
for f  D do
S , W S , and Z S according to Eqs. 35, 44, 53 using γ , γ , and γ ;
Update Puf
P W
Z
uf
uf
S , W t S , and Zt S
t
according
to
Eqs.
38,
41,
44
using
γ P t , γW t , and γ Z t ;
∀t ∈ Iu : Update Ptuf
uf t
uf t
t
Z
P
W
Update βuf , βuf , and βuf according to Eqs. 41, 44, 47 using γ α P , γ α W , and γ α Z ;
∀t ∈ Iut : Update ωvt f according to Eq. 51 using γ ω ;
f ← f + 1;
v ← v + 1;
u ← u + 1;
}

Algorithm 5 Model Updating
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:

void ModelUpdater(λ, γ )
{
S ;
∀u, f : Puf ← −γU × Puf
∀u : αuP ← −γ α P × βuP ;
S ;
∀u, f : Wuf ← −γW × Wuf
∀u : αuW ← −γ α W × βuW ;
S ;
∀u, f : Zuf ← −γ Z × Zuf
∀u : αuZ ← −γ α Z × βuZ ;
S ;
∀u, f : ωuf ← −γ ω × ωuf
}

C(IntrinsicTrainer ) = O(D × |R|) + O(D × |T |)

(24)

In the Model Updater, the values of matrices P, W , Z , and vectors ω, α P , α W , and α Z need to be
updated. The computation time needed to update these parameters is O(N × D). Assuming that
each user has rated at least one item, it is safe to say that |R| is greater than the number of users N .
Therefore, the computation time of Model Updater does not exceed the maximum computation
time of Intrinsic Trainer and Social Trainer. Finally, the computation time of the Model trainer is
obtained as Eq. 25.
C(ModelTrainer ) = O(D 2 × |R|) + O(D × |T |)

(25)

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:20

Zafari et al.

The number of latent factors D is fixed, hence the computation time is only a function of |R| and
|T |. Since both ratings matrix and social network matrix are sparse, the algorithm is scalable to the
problems with millions of users and items.
4
4.1

EXPERIMENTS
Datasets

We tested Aspect-MF on three popular datasets, Ciao, Epinions, and Flixster. Ciao is a dataset
crawled from the ciao.co.uk website. This dataset includes 35,835 ratings given by 2,248 users
over 16,861 movies. Ciao also includes the trust relationships between users. The number of trust
relationships in Ciao is 57,544. Therefore the dataset density of ratings and trust relationships are
0.09% and 1.14% respectively. The ratings are integer values between 1 and 6. The Epinions dataset
consists of 664,824 ratings from 40,163 users on 139,738 items of different types (software, music,
television show, hardware, office appliances, ...). Ratings are integer values between 1 and 5, and
data density is 0.011%. Epinions also enables the users to issue explicit trust statements about other
users. This dataset includes 487183 trust ratings. The density of the trust network is 0.03%. Flixster
is a social movie site which allows users to rate movies and share the ratings with each other,
and become friends with others with similar movie taste. The Flixster dataset which is collected
from the Flixster website includes 8,196,077 ratings issued by 147,612 users on 48,794 movies. The
social network also includes 7,058,819 friendship links. The density of the ratings matrix and social
network matrix are 0.11% and 0.001% respectively.
In all the experiments in sections 4.3, 4.4, and 4.5, 80% of the datasets are used for training and
the remaining 20% are used for evaluation. In order to achieve statistical significance, each model
training is repeated for 30 times and the average values are used. In section 4.6, we analyse the
behaviour of the models in other cases, where 60% and 40% of the ratings are used for training.
4.2

Comparisons

In order to show the effectiveness of Aspect-MF, we compared the results against the recommendation quality of some of the most popular state of the art models that have reported the highest
accuracies in the literature. The following models are compared across the experiments in this
section:
• TrustSVD [6], which builds on SVD++ [14]. The missing ratings are calculated based on
explicit and implicit feedback from user ratings and user’s trust relations.
• CondTrustFVSVD [32], this method extends TrustSVD by adding the conditional preferences
over feature values to TrustSVD. Experimental results show that this method is significantly superior to TrustSVD in terms of accuracy. This model is denoted CTFVSVD in the
experiments section.
• Aspect-MF, which is the model proposed in this paper. The component-based approach that
we took in designing this model enabled us to arbitrarily switch on/off the dynamicity over
different preference aspects. Therefore, in the experiments we try all the combinations of
dynamic preference aspects. This results in 7 combinations denoted by b, b f , b f f v, b f v,
f , f f v, and f v 1 .
Guo, Zhang and Yorke-Smith [7] carried out comprehensive experiments, and showed that their
model, TrustSVD outperformed all the state of the art models. Recently, Zafari and Moser [32]
showed that their model CondTrustFVSVD significantly outperforms TrustSVD. Therefore, in
1 fv denotes feature value preferences, f denotes feature preferences, and b denotes bias. Therefore, bffv denotes a
model with all the three aspects.

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:21

this section, we limited our comparisons to these two models from the state of the art, since they
outperform a comprehensive set of state of the art recommendation models [7, 32].
The optimal experimental settings for each method are determined either by our experiments or
suggested by previous works [6, 7, 33]. Due to the over-fitting problem, the accuracy of iterative
models improves for a number of iterations, after which it starts to degrade. Therefore, we recorded
the best accuracy values achieved by each model during the iterations, and compared the models
based on the recorded values. We believe that this approach results in a fairer comparison of the
models than setting the number of iterations to a fixed value, because the models over-fit at different
iterations, and using a fixed number of iterations actually prevents us from fairly comparing the
models based on their real capacity in uncovering hidden patterns from data. Therefore, the reported
results for iterative models here are the best results that they could achieve using the aforementioned
parameters. MAE and RMSE measures are used to evaluate and compare the accuracy of the models.
MAE and RMSE are two standard and popular measures that are used to measure and compare the
performance of preference modelling methods in recommender systems. In the following sections,
we consider the performances separately for All Users and Cold-start Users. Cold-start Users are
the users who have rated less than 5 items, and All Users include all the users regardless of the
number of items they have rated.
4.3

Discussion

All latent factor approaches have been evaluated with 5 factors, because no clear ideal value could
be established. In section 4.3.1, first we analyse the performance of the models from different
perspectives. Since the results are subject to randomness, we also performed a t test to guarantee
that the out-performances achieved do not happen by chance. The results are discussed in section
4.4. As we mentioned in section 1, one of the research questions we are interested in, in this paper
is related to the interplay between the dynamicity of preference aspects and the preference domain.
In section 4.5, we consider the performance of combinations of Aspect-MF, in order to pinpoint the
aspects that are more subject to temporal drift in each dataset. In section 4.6, we also consider the
effect of the amount of training data that is fed to the model as input, and analyse the robustness
of the models to the shortage of training data.
4.3.1 Model performances. We can consider the performance of the models from different
perspectives. A preference model’s performance can be considered with respect to the dataset on
which it is trained, the accuracy measure that is used to evaluate the model’s performance, and the
performance of the model on cold-start users vs the performance on all users.
Datasets. The error values in Fig. 5 show that the Aspect-MF results in substantial improvements
over TrustSVD in all three datasets for both measures and for all users and cold-start users. As we
can see in this figure, the box plots of Aspect-MF’s combinations do not have much overlap with
the box plot of TrustSVD, which means that the differences are definitely statistically significant. In
this figure, we can also see that the box plot widths for Aspect-MF’s combinations are usually much
smaller than that for TrustSVD. This suggests that Aspect-MF’s combinations are more stable than
TrustSVD, meaning that they find roughly the same solutions across different model executions.
This is a favourable property of the model, since it makes the model performance less subject
to randomness. Clearly, a model that performs well sometimes and worse at other times is less
reliable. The model’s superior performance is likely due to its taking multiple preference aspects
into account, therefore, it has more clues as to where the optimal solutions might reside in the
solution space.
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:22

Zafari et al.

In particular, we can see that the model is more stable in the case of the Ciao and Epinions
datasets than the Flixster dataset. On the Epinions dataset, each typical user and cold-start user
rates 41.61 items and 4.08 items on average. These numbers respectively are 15.94 and 2.94 for the
Ciao dataset, and 11.12 and 1.94 for the Flixster dataset. This could explain why the variations are
larger on Flixster dataset than Epinions and Ciao datasets. Since more ratings per user are available
in the Ciao and Epinions dataset, different executions lead the model to more similar solutions than
the solutions that are found on the Flixster dataset across different model executions. We can also
see from Table 1, that on the Ciao and Flixster datasets, the improvements are more significant for
RMSE, while more significant improvements are achieved for RMSE. We can also clearly observe
that the model variations are smaller for all users in the Epinions dataset, and for cold-start users
in the Flixster dataset.
Ciao-MAE ALL
0.629
0.628
0.627
0.626
0.625
0.624
0.623
0.622
0.621
0.620
0.619
0.618
0.617
0.616
0.615
0.614
0.613
0.612
0.611
0.610
0.609
0.608
0.607
0.606
0.605
0.604
0.603
0.602
0.601
0.600
0.599
0.598
0.597
0.596
0.595
0.594
0.593
0.592
0.591
0.590
0.589
0.588
CTFVSVD

b

f

fv

bf
Model

bfv

ffv

bffv

TrustSVD

0.596
0.595
0.594
0.593
0.592
0.591
0.590
0.589
0.588
0.587
0.586
0.585
0.584
0.583
0.582
0.581
0.580
0.579
0.578
0.577
0.576
0.575
0.574
0.573
0.572
0.571
0.570
0.569
0.568
0.567
0.566
0.565
0.564
0.563
0.562
0.561
0.560
0.559
0.558
0.557
0.556
0.555
0.554
0.553
0.552
0.551
0.550
0.549

Ciao-MAE CS

CTFVSVD

b

(a) MAE, all users

f

fv

b

f

fv

bf
Model

bfv

ffv

bffv

TrustSVD

bffv

TrustSVD

(b) MAE, cold-start users

Ciao-RMSE ALL

Ciao-RMSE CS

0.950
0.948
0.946
0.944
0.942
0.940
0.938
0.936
0.934
0.932
0.930
0.928
0.926
0.924
0.922
0.920
0.918
0.916
0.914
0.912
0.910
0.908
0.906
0.904
0.902
0.900
0.898
0.896
0.894
0.892
0.890
0.888
0.886
0.884
0.882
0.880
0.878
CTFVSVD

bf
Model

bfv

ffv

bffv

TrustSVD

0.934
0.932
0.930
0.928
0.926
0.924
0.922
0.920
0.918
0.916
0.914
0.912
0.910
0.908
0.906
0.904
0.902
0.900
0.898
0.896
0.894
0.892
0.890
0.888
0.886
0.884
0.882
0.880
0.878
0.876
0.874
0.872
0.870
0.868
0.866
0.864
0.862
0.860
0.858
0.856
0.854
0.852
0.850
0.848

(c) RMSE, all users

CTFVSVD

b

f

fv

bf
Model

bfv

ffv

(d) RMSE, cold-start users

Fig. 5. Box plots of the Aspect-MF’s combinations (b, bf, bffv, f, ffv, fv) and CTFVSVD versus TrustSVD
in Ciao dataset in terms of MAE and RMSE measures for cold-start users (CS) and all users (ALL).

Accuracy measures. As the statistical analysis of the models in Table 1 show, the differences
are generally more significant when the accuracies are measured in terms of the RMSE. This can
be explained by the formulation of these models as an optimisation problem. These models focus
on maximising accuracy using RMSE and achieving better MAE values is a secondary goal that is
only pursued through minimising RMSE.
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach
Epinions-MAE ALL

1:23

Epinions-MAE CS

0.8100
0.8095
0.8090
0.8085
0.8080
0.8075
0.8070
0.8065
0.8060
0.8055
0.8050
0.8045
0.8040
0.8035
0.8030
0.8025
0.8020
0.8015
0.8010
0.8005
0.8000
0.7995
0.7990
0.7985
0.7980
0.7975
0.7970
0.7965
0.7960
0.7955
0.7950
0.7945
0.7940
0.7935
0.7930
0.7925
0.7920
0.7915

0.8420
0.8415
0.8410
0.8405
0.8400
0.8395
0.8390
0.8385
0.8380
0.8375
0.8370
0.8365
0.8360
0.8355
0.8350
0.8345
0.8340
0.8335
0.8330
0.8325
0.8320
0.8315
0.8310
0.8305
0.8300
0.8295
CTFVSVD

b

f

fv

bf
Model

bfv

ffv

bffv

TrustSVD

CTFVSVD

b

(a) MAE, all users

f

fv

1.0480
1.0475
1.0470
1.0465
1.0460
1.0455
1.0450
1.0445
1.0440
1.0435
1.0430
1.0425
1.0420
1.0415
1.0410
1.0405
1.0400
1.0395
1.0390
1.0385
1.0380
1.0375
1.0370
1.0365
1.0360
1.0355
1.0350
1.0345
1.0340
1.0335
1.0330
f

fv

bf
Model

ffv

bffv

TrustSVD

bffv

TrustSVD

Epinions-RMSE CS

1.0485

b

bfv

(b) MAE, cold-start users

Epinions-RMSE ALL
1.0490

CTFVSVD

bf
Model

bfv

ffv

(c) RMSE, all users

bffv

TrustSVD

1.0898
1.0896
1.0894
1.0892
1.0890
1.0888
1.0886
1.0884
1.0882
1.0880
1.0878
1.0876
1.0874
1.0872
1.0870
1.0868
1.0866
1.0864
1.0862
1.0860
1.0858
1.0856
1.0854
1.0852
1.0850
1.0848
1.0846
1.0844
1.0842
1.0840
1.0838
1.0836
1.0834
1.0832
1.0830
1.0828
1.0826
1.0824
1.0822
1.0820
1.0818
1.0816
1.0814

CTFVSVD

b

f

fv

bf
Model

bfv

ffv

(d) RMSE, cold-start users

Fig. 6. Box plots of the Aspect-MF’s combinations (b, bf, bffv, f, ffv, fv) and CTFVSVD versus TrustSVD
in Epinions dataset in terms of MAE and RMSE measures for cold-start users (CS) and all users
(ALL).

Cold-start vs all users. By taking a close look at the statistical analysis results in Table 1 and
also the box plots of CTFVSVD vs Aspect-MF’s combinations in Fig. 5, we can see that in all three
datasets, the improvements of the Aspect-MF are more significant over all users than cold-start
users. This can be explained by the amount of dynamic information that the models receive for
each one of these groups of users. For all users, the model is trained using all ratings and also
all associated time stamps for those ratings. Therefore the model can more successfully discern
the temporal patterns in the preferences, and the accuracy improvements are larger. However, for
the cold-start users, the model does not have access to much temporal information about these
users, since they do not have many ratings. As a result, the model cannot identify the shift in the
preferences of these users, and the improvements are smaller. From this, we conclude that temporal
models are more successful on all users, because for them, temporal information is available.
4.4

Statistical analysis

The statistical analysis of the performances provided in Table 1 shows that all Aspect-MF’s combinations achieve significantly better results than TrustSVD, which does not include the temporal
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:24

Zafari et al.
Flixster-MAE ALL

0.7070
0.7065
0.7060
0.7055
0.7050
0.7045
0.7040
0.7035
0.7030
0.7025
0.7020
0.7015
0.7010
0.7005
0.7000
0.6995
0.6990
0.6985
0.6980
0.6975
0.6970
0.6965
0.6960
0.6955
0.6950
0.6945
0.6940
0.6935
0.6930
0.6925
0.6920
0.6915
0.6910
0.6905
0.6900
0.6895
0.6890

CTFVSVD

b

f

fv

bf
Model

bfv

ffv

bffv

TrustSVD

0.798
0.797
0.796
0.795
0.794
0.793
0.792
0.791
0.790
0.789
0.788
0.787
0.786
0.785
0.784
0.783
0.782
0.781
0.780
0.779
0.778
0.777
0.776
0.775
0.774
0.773
0.772
0.771
0.770
0.769
0.768
0.767
0.766
0.765
0.764
0.763
0.762
0.761
0.760
0.759
0.758
0.757
0.756

Flixster-MAE CS

CTFVSVD

b

(a) MAE, all users

f

fv

bfv

ffv

bffv

TrustSVD

bffv

TrustSVD

(b) MAE, cold-start users

Flixster-RMSE ALL

Flixster-RMSE CS

0.9210

1.012

0.9205

1.011

0.9200

1.010
1.009

0.9195

1.008

0.9190

1.007

0.9185

1.006

0.9180

1.005

0.9175

1.004
1.003

0.9170

1.002

0.9165

1.001

0.9160

1.000

0.9155

0.999

0.9150

0.998
0.997

0.9145

0.996

0.9140

0.995

0.9135

0.994

0.9130

0.993

0.9125

0.992
0.991

0.9120

0.990

0.9115

0.989

0.9110

0.988

0.9105

0.987
0.986

0.9100
0.9095

bf
Model

0.985
CTFVSVD

b

f

fv

bf
Model

bfv

ffv

bffv

TrustSVD

(c) RMSE, all users

CTFVSVD

b

f

fv

bf
Model

bfv

ffv

(d) RMSE, cold-start users

Fig. 7. Box plots of the Aspect-MF’s combinations (b, bf, bffv, f, ffv, fv) and CTFVSVD versus TrustSVD
in Flixster dataset in terms of MAE and RMSE measures for cold-start users (CS) and all users (ALL).

information. The values in Table 2 also show that Aspect-MF’s combinations also result in improvements over CTFVSVD that are statistically significant, which means that in all three datasets,
Aspect-MF has been successful in extracting the temporal patterns in the users’ preferences. We
can also see that the all the p values in Table 1 are 0.0000, which means that with almost 100%
probability, the two model executions (Aspect-MF and TrustSVD) do not come from distributions
with equal mean performances. Therefore, we are almost 100% sure that the observed differences in
performance are due to the superiority of Aspect-MF over TrustSVD, and not the result of chance.
Similarly, the p values in Table 2 are almost zero, which means that we are certain that Aspect-MF
is better than CTFVSVD, in cases where the t test shows a statistically significant improvement.
4.5

Dynamic aspects

The close comparison of the error values achieved by Aspect-MF in Fig. 3 show that in terms of MAE
for all users, Aspect-MF achieves the best performance on the Ciao and Epinions datasets, for the
models including dynamic b and f aspects. However, on the Flixster dataset, the model combination
with dynamic b and f v aspects performs best. Interestingly, for cold-start users, different models
perform the best. In particular, on the Ciao dataset, the model including dynamic f performs best,
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:25

whereas on the Epinions and Flixster datasets, the model including dynamic b, f , and f v aspects,
and the model with drifting f aspect achieve the best results respectively. Furthermore, the error
values in Fig. 4 show that different model combinations might achieve the best performances for
RMSE. From these figures, we can make several conclusions.
The first conclusion is that the dynamic patterns are dataset-dependent. Therefore, users and
the items in different dataset can have preferences with aspects with different levels of dynamicity.
This finding supports our component-based approach in modelling the dynamic properties of the
preference aspects.
The second conclusion is that the prediction of the ratings for the cold-start users is less dependent
on the drifting bias than that of all users. As we see in this Figures 3 and 4, for all users, the
combinations that include dynamic b aspects are strictly better than the other combinations, whilst
this is less consistent for cold-start users, where sometimes the models with only dynamic f aspects
perform best. This suggests that the preferences of cold-start users are not much affected by the
shifts in the popularity of the items, while other users’ preferences are more influenced by such
shifts. Therefore, the accurate modelling of such temporal effects is of greater importance in the
case of all users than cold-start users. As previous studies have shown [11], bias is a very important
aspect in human preferences. Since the cold-start users do not have enough ratings, there is also
not enough temporal data to train the preferences for these models. Therefore, the trained temporal
aspects of these users are probably not very accurate, and therefore, the combinations that include
bias perform poorly on these users, due to imprecise predictions.
The third conclusion is that both measures reveal roughly the same preference patterns. This
seems justifiable, since the shift in user preferences should naturally be independent of how the
differences in estimated preferences and real preferences are measured.
To summarise, it is very advantageous to have a component-based model in which the temporal
aspects of preferences can be arbitrarily captured in different conditions. This enables us to capture
the patterns only when they are actually helpful, and consequently, build the most accurate
preference models, tailored to different datasets and domains with disparate temporal patterns.

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:26
Dynamic Model

Zafari et al.
Measure

Ciao

Epinions
t value

Aspect-MF(b)
Aspect-MF(b)
Aspect-MF(b)
Aspect-MF(b)
Aspect-MF(bf)
Aspect-MF(bf)
Aspect-MF(bf)
Aspect-MF(bf)
Aspect-MF(bffv)
Aspect-MF(bffv)
Aspect-MF(bffv)
Aspect-MF(bffv)
Aspect-MF(bfv)
Aspect-MF(bfv)
Aspect-MF(bfv)
Aspect-MF(bfv)
Aspect-MF(f)
Aspect-MF(f)
Aspect-MF(f)
Aspect-MF(f)
Aspect-MF(ffv)
Aspect-MF(ffv)
Aspect-MF(ffv)
Aspect-MF(ffv)
Aspect-MF(fv)
Aspect-MF(fv)
Aspect-MF(fv)
Aspect-MF(fv)

MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS

-19.9867
-48.7869
-24.9813
-61.0847
-20.2987
-48.3137
-24.2062
-58.0125
-20.1253
-48.7184
-26.7303
-62.6826
-20.0161
-48.7855
-25.0275
-61.8785
-16.021
-40.3613
-31.3473
-62.008
-16.4344
-41.942
-30.1691
-60.9112
-16.8998
-42.4293
-30.0768
-61.5278

p value Sig.

t value

yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes

-144.389
-138.903
-60.0446
-35.8673
-144.517
-137.679
-57.2661
-35.1151
-144.792
-138.854
-57.8678
-35.6445
-140.994
-135.65
-57.4134
-35.8765
-126.805
-120.674
-59.4225
-36.5189
-131.061
-124.216
-60.2686
-34.5646
-127.613
-121.779
-57.1987
-33.735

9.44E-20
2.09E-33
9.60E-29
1.94E-40
1.75E-20
8.60E-35
5.78E-30
2.90E-44
1.36E-19
2.40E-32
1.60E-26
2.88E-37
5.51E-20
2.22E-32
4.47E-30
4.54E-39
1.28E-17
2.93E-33
9.40E-33
1.76E-40
1.37E-17
1.31E-30
9.47E-34
2.12E-41
1.42E-17
1.93E-31
2.88E-32
2.68E-40

Flixster
p value Sig.

t value

yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes

-18.3981
-11.0414
-37.612
-27.6887
-17.6976
-11.3137
-37.6646
-28.4271
-18.9756
-11.9005
-37.5037
-27.5707
-18.304
-11.7557
-39.183
-28.9199
-15.2094
-9.14701
-34.6759
-27.0282
-15.2416
-9.28969
-36.8921
-27.7828
-16.0515
-9.22016
-38.164
-27.2901

3.57E-49
6.05E-49
2.75E-40
7.73E-32
2.80E-49
3.67E-50
2.06E-44
7.69E-34
1.23E-48
1.08E-48
1.57E-42
1.44E-31
5.74E-52
1.02E-51
9.13E-44
9.44E-33
1.94E-50
2.03E-50
5.52E-42
3.76E-31
1.17E-46
4.87E-47
2.61E-40
1.19E-32
1.55E-49
2.10E-49
4.54E-43
7.11E-33

p value Sig.
2.33E-21
8.14E-14
1.36E-34
9.62E-29
1.66E-21
6.28E-14
2.67E-34
2.65E-28
1.21E-21
1.72E-14
4.99E-35
1.45E-29
9.83E-23
1.50E-14
1.14E-31
9.04E-27
8.52E-20
2.32E-11
2.87E-36
2.79E-28
1.30E-18
4.00E-11
3.11E-34
1.94E-28
2.37E-19
4.64E-11
6.52E-33
2.64E-28

yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes
yes

Table 1: The t values and p values for Aspect-MF’s combinations vs TrustSVD in Ciao, Epinions, and
Flixster datasets for MAE and RMSE measures on all users (ALL) and cold-start users (CS)

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach
Dynamic Model

Measure

Ciao

Epinions
t value

Aspect-MF(b)
Aspect-MF(b)
Aspect-MF(b)
Aspect-MF(b)
Aspect-MF(bf)
Aspect-MF(bf)
Aspect-MF(bf)
Aspect-MF(bf)
Aspect-MF(bffv)
Aspect-MF(bffv)
Aspect-MF(bffv)
Aspect-MF(bffv)
Aspect-MF(bfv)
Aspect-MF(bfv)
Aspect-MF(bfv)
Aspect-MF(bfv)
Aspect-MF(f)
Aspect-MF(f)
Aspect-MF(f)
Aspect-MF(f)
Aspect-MF(ffv)
Aspect-MF(ffv)
Aspect-MF(ffv)
Aspect-MF(ffv)
Aspect-MF(fv)
Aspect-MF(fv)
Aspect-MF(fv)
Aspect-MF(fv)

MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS
MAE-ALL
RMSE-ALL
MAE-CS
RMSE-CS

-7.9254
-17.5792
8.9344
0.5979
-8.6722
-16.9178
7.6174
0.4274
-8.2488
-17.2079
10.1601
2.0086
-8.0096
-17.3742
7.3472
1.0133
0.6250
-1.1529
1.0076
-0.8901
0.1020
-1.1275
1.0049
-0.2707
-0.5989
-2.9847
2.3939
0.0763

p value Sig.

t value

yes
yes
yes
no
yes
yes
yes
no
yes
yes
yes
yes
yes
yes
yes
no
no
no
no
no
no
no
no
no
no
yes
yes
no

-40.0588
-34.3869
0.8529
1.4063
-40.4729
-32.7924
0.0021
0.4595
-40.8591
-34.0360
1.2975
1.9330
-33.8218
-30.0663
0.5237
0.5666
0.6578
1.7569
-0.0942
1.2122
-0.0859
1.7583
0.5245
2.1764
0.9751
1.6778
1.5299
2.8533

0.0000
0.0000
0.0000
0.5522
0.0000
0.0000
0.0000
0.6709
0.0000
0.0000
0.0000
0.0495
0.0000
0.0000
0.0000
0.3151
0.5345
0.2539
0.3179
0.3771
0.9191
0.2643
0.3191
0.7876
0.5520
0.0042
0.0200
0.9394

1:27

Flixster
p value Sig.

t value

yes
yes
no
no
yes
yes
no
no
yes
yes
no
no
yes
yes
no
no
no
no
no
no
no
no
no
yes
no
no
no
yes

-3.51234
-3.76619
-0.85677
-1.70069
-2.88722
-4.13771
-0.65626
-2.23892
-4.31919
-5.11012
-1.11763
-2.18501
-4.19593
-4.92428
-0.31262
-1.76305
0.169793
-0.53474
0.644178
-0.62142
1.302566
-0.32867
0.350768
-1.57954
0.086061
-0.22597
-0.03512
-0.92614

0.0000
0.0000
0.3973
0.1650
0.0000
0.0000
0.9983
0.6476
0.0000
0.0000
0.1996
0.0582
0.0000
0.0000
0.6025
0.5732
0.5139
0.0846
0.9253
0.2306
0.9318
0.0840
0.6019
0.0336
0.3343
0.0990
0.1315
0.0060

p value Sig.
8.76E-04
3.90E-04
0.39517
0.094359
0.005453
1.16E-04
0.514293
0.029057
6.39E-05
3.90E-06
0.26848
0.032959
9.50E-05
7.44E-06
0.755723
0.083675
0.865773
0.594882
0.522319
0.536762
0.197918
0.743682
0.727059
0.119666
0.931718
0.822071
0.972102
0.358215

yes
yes
no
no
yes
yes
no
yes
yes
yes
no
yes
yes
yes
no
no
no
no
no
no
no
no
no
no
no
no
no
no

Table 2: The t values and p values for Aspect-MF’s combinations vs CTFVSVD in Ciao, Epinions, and
Flixster datasets for MAE and RMSE measures on all users (ALL) and cold-start users (CS)

4.6

Effect of the size of the training dataset

The main purpose of this section is to evaluate the robustness of the models against shortage of
training data. In the experiments in sections 4.3 through 4.5, 80% of the ratings matrix was used for
training the models and the remaining data was used for evaluation. The question that arises here
is how the models would perform if less amount of data was fed to the models for training.
In order to analyse the behaviour of the models with respect to the amount of training data, we
can reduce the amount of the training data, and consider how much the accuracy drops as the
training data is decreased. Therefore, we also evaluate the models in two additional cases. The first
case includes 60% of the data for training, and the remaining 40% for testing, and the second case
uses 40% of ratings data for training and the rest for evaluation. The results for the Flixster and
Ciao datasets are demonstrated in Figs. 5 and 6 respectively. These figures show the percentage of
error increase as the amount of training data is decreased.
All users. As can be seen in Fig. 5, on the Flixster dataset, in the case of all users, all combinations
of Aspect-MF result in a smaller increase in the error when the training data is decreased from
80% to 60% (denoted by 80-60 in these diagrams), and from 60% to 40% (denoted by 60-40 in these
diagrams). Furthermore, we can observe that in terms of MAE, the combination that includes f and
f v resulted the smallest error increase when the training data decreased from 80% to 60%, and the
model that included f v resulted in the smallest error increase when the training data decreased
from 60% to 40%. This suggests that the dynamic model is more robust to the shortage of training
data, when the error is measured in terms of MAE for all users. In terms of RMSE, the least accuracy
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:28

Zafari et al.
0.562
0.561

0.595

0.56

0.594

0.559

MAE-CS

MAE-ALL

0.596

0.593

0.557

0.592
0.591

0.558
0.556

b

bf bffv bfv f ffv
Model
a) MAE all users, Ciao

0.555

fv

b

bf

bffv bfv f
ffv
Model
b) MAE CS users, Ciao

fv

0.83065
0.8306
MAE-CS

MAE-ALL

0.7938
0.7933
0.7928
0.7923

0.8305
b

0.83045

bf bffv bfv f ffv fv
Model
c) MAE all users, Epinions

0.695

MAE-CS

MAE-ALL

0.6945
0.694
0.6935
0.693

0.83055

b

bf bffv bfv f ffv fv
Model
e) MAE all users, Flixster

0.7629
0.7628
0.7627
0.7626
0.7625
0.7624
0.7623
0.7622
0.7621
0.762

b

b

bf bffv bfv f ffv fv
Model
d) MAE CS users, Epinions

bf bffv bfv f ffv
Model
f) MAE CS users, Flixster

Fig. 3. Comparisons of the MAE values of Aspect-MF’s combinations in a,b) Ciao, c,d) Epinions, and
e,f) Flixster datasets for all users (MAE-ALL) and cold-start users (MAE-CS)
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

fv

0.892

0.8576

0.89

0.8572

0.888
0.886

b

bf bffv bfv f ffv
Model
a) RMSE all users, Ciao

0.8566

0.856

fv

1.0345
1.034

fv

1.08265
1.0826
1.08255

b

1.0825

bf bffv bfv f ffv fv
Model
c) RMSE all users, Epinions

b

bf bffv bfv f ffv fv
Model
d) RMSE CS users, Epinions

RMSE-CS

0.9135

0.9896

0.913

RMSE-CS

RMSE-ALL

bffv bfv f
ffv
Model
b) RMSE CS users, Ciao

1.0827

RMSE-ALL

0.9125
0.912
0.9115

bf

1.08275
RMSE-CS

1.035

b

1.0828

1.0355
RMSE-ALL

0.8568

0.8562

RMSE-ALL

1.0335

0.857

0.8564

0.884
0.882

1:29

0.8574
RMSE-CWS

RMSE-ALL

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

b

bf bffv bfv f ffv fv
Model
e) RMSE all users, Flixster

0.9894
0.9892
0.989

b

bf

bffv bfv f
ffv fv
Model
f) RMSE CS users, Flixster

Fig. 4. Comparisons of the MAE values of Aspect-MF’s combinations in a,b) Ciao, c,d) Epinions, and
e,f) Flixster datasets for all users (RMSE-ALL) and cold-start users (RMSE-CS)
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:30

Zafari et al.

deterioration happened for the model combination with the f aspect, both when the training data
amount drops to 60%, and when it drops to 40%.
Cold-start users. For cold-start users however, a different pattern is evident. Interestingly, we
can see that for cold-start users, the error increases more when the training data is decreased from
80% to 60%, compared to when it is decreased from 60% to 40%. This means that the accuracy
degrades more when the training data drops to 60%. Judging by the higher error increase for
cold-start users in comparison with all users, cold-start users seem to be more sensitive to the
decrease in the amount of training data. This seems understandable, since the cold-start users do
not have many ratings. Therefore, when evaluating the model accuracy for cold-start users, less
accurate predictions for each rating have a larger effect on the overall accuracy.
TrustSVD seems to be more robust to the shortage of training data for cold-start users, when
the training data drops from 60% to 40%. This can be attributed to the fact that the dynamic model
contains time information, and this information can be misleading if we substantially decrease
the amount of training data, and evaluate the accuracy for cold-start users who do not have much
ratings. A similar observation was made in Figs. 3 and 4, where the dynamic model including the b
aspect performed poorly on the cold-start users.

CS

ALL
5

a)

2.4

4.5

2
1.8
80-60
60-40

1.6

MAE-CS Increase (%)

MAE-ALL Increase (%)

2.2

MAE

b)

4
80-60
60-40

3.5

1.4

3
1.2

2.5

1
CTFVSVD

b

bf

bffv

bfv

f

ffv

fv

CTFVSVD

TrustSVD

b

bf

bffv

bfv

f

ffv

fv

TrustSVD

Model

Model

c)

d)

3

1.7

2.6

1.3
80-60
60-40
1.1

RMSE-CS Increase (%)

1.5

RMSE-ALL Increase (%)

RMSE

2.8

2.4
2.2
80-60
2

60-40

1.8
1.6

0.9

1.4
1.2

0.7
CTFVSVD

b

bf

bffv

bfv

f

ffv

fv

TrustSVD

Model

CTFVSVD

b

bf

bffv

bfv

f

ffv

fv

TrustSVD

Model

Fig. 5. Effect of the training amount on Flixster dataset for a) MAE for all users, b) MAE for cold-start
users, c) RMSE for all users, d) RMSE for cold-start users

All users vs cold-start users. A similar trend to the one observed in Flixster dataset can also be
seen in the Ciao dataset in Figure 6. As this figure shows, the accuracy deterioration for cold-start
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:31

users is much larger compared with that for all users. Again, we attribute this to the high sensitivity
of cold-start users to inaccurate predictions. For the case where the training data amount drops
from 80% to 60%, the model combination with all the dynamic aspects (b f f v) results in the lowest
increase in MAE for all users. For cold-start users, the model combination with b and f aspects
achieve the smallest deterioration of accuracy.
However, in terms of RMSE for all users, TrustSVD incurs the lowest increase in the error,
while for cold-start users, the model with the dynamic f v aspect is the most robust. In the second
case where the training data amount is decreased from 60% to 40%, at least one of the model
combinations performs best (incurs the lowest accuracy deterioration) for each measure, among
the models tested. We can also see that when the training data amount is decreased from 80% to
60%, the error increase is much lower than when the training data amount drops from 60% to 40%.
This means that the models are still quite robust with 60% of the ratings data as training data, but
their accuracy considerably drops when the training data decreases to 40%.
Flixster vs Ciao. One of the key differences between the behaviour of the models on the Flixster
and Ciao datasets, as can be seen in Figs. 5 and 6, is the threshold at which the accuracy sharply
drops for cold-start users. For the Flixster dataset, the accuracy of cold-start users sharply worsens
when the training data amount is decreased from 80% to 60%, while for the Ciao dataset, the sharp
decrease in accuracy happens when the training data amount decreases from 60% to 40%. This
can be easily justified by looking at the statistics of these two datasets for cold-start users. On the
Flixster dataset as we mentioned before, each cold-start user rates 1.94 items on average, while
this number is 2.94 in the Ciao dataset. Therefore, the accuracy of cold-start users on the Flixster
dataset is more sensitive to inaccurate predictions than that on the Ciao dataset.
Considering all four measures on the two datasets, in general, we can observe that Aspect-MF’s
combinations are more robust to the decrease in the amount of training information than TrustSVD
and CTFVSVD. The combinations in this paper are particularly more helpful in cases where enough
time related data is fed into the model as input.
Insights. From the observations for cold-start users, we can conclude that in order for the time
information to be helpful, we need to provide the model with enough time-related data as input, so
that the accuracy can be improved, and the importance of such data is more pronounced for the
cold-start users, whose predictions are more sensitive to the inaccuracies. Otherwise, if the amount
of training data is insufficient, the model can learn unrealistic temporal patterns that directly result
from a shortage of training information.
We also saw that the degree of deterioration of the accuracy is somewhat dependent on the dataset.
On the Flixster, the accuracy degrades somewhere between just under 1% to just under 5%. On
Ciao, however, the accuracy deteriorates much more (roughly between 6.5% and 19.5%). Therefore,
it is up to the system users to decide whether they would like to use smaller datasets and sacrifice
the accuracy, or spend more time on training more accurate models using more information. We
did not observe any tangible differences between the execution times of these cases (80%-60%-40%),
and the computational complexity analysis of the model in section 3.2.5 showed that the model
time is of linear order. Therefore, it is probably advisable for the system owners to use as much
data as available to achieve the highest accuracies, as long as their computational limitations allow.
5

CONCLUSION AND FUTURE WORK

In this paper, we addressed the problem of modelling the temporal properties of human preferences
in recommender systems. In order to tackle this problem, we proposed a novel latent factor model
called Aspect-MF. Aspect-MF built on the basis of CTFVSVD, a model that we proposed earlier,
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:32

Zafari et al.

CS

ALL
a)

16.5

b)

20.5

19.5

15.5

13.5

80-60
60-40

12.5

MAE-CS Increase (%)

MAE-ALL Increase (%)

MAE

18.5

14.5

17.5
80-60
16.5

60-40

15.5

11.5

14.5

10.5

13.5
CTFVSVD

b

bf

bffv

bfv

f

ffv

fv

TrustSVD

CTFVSVD

b

bf

bffv

Model

bfv

c)

10.5

f

ffv

fv

TrustSVD

Model

d)

14.2

10
13.2

9
8.5

80-60
60-40

8

RMSE-CS Increase (%)

RMSE-ALL Increase (%)

RMSE

9.5

12.2
80-60
60-40

11.2

7.5
10.2

7
6.5

9.2
CTFVSVD

b

bf

bffv

bfv

f

ffv

fv

TrustSVD

Model

CTFVSVD

b

bf

bffv

bfv

f

ffv

fv

TrustSVD

Model

Fig. 6. Fig. 11: Effect of the training amount on Ciao dataset for a) MAE for all users, b) MAE for
cold-start users, c) RMSE for all users, d) RMSE for cold-start users

in order to capture socially-influenced conditional preferences over feature values. In Aspect-MF,
three major preference aspects were assumed to be subject to temporal drift. These aspects included
user and item biases, preferences over features, and preferences over feature values. Moreover, we
also analysed the temporal behaviour of each of these preference aspects and their combinations.
We also considered the robustness of Aspect-MF’s combinations with respect to the shortage of
training data.
In order to evaluate the model, we carried out extensive experiments on three popular datasets in
the area of recommender systems. We considered the model errors in terms of MAE and RMSE measures on all users and cold-start users. We also performed statistical analyses on the performances
observed, to make sure that the differences in accuracies are significant, and hence do not happen
by chance. The experiments revealed that in all three datasets, all combinations of Aspect-MF for
both measures on all users and cold-start users significantly outperformed TrustSVD, which had
proven to be the most accurate static social recommendation model before CTFVSVD. The experiments also proved that most of the Aspect-MF’s combinations were significantly more accurate
than CTFVSVD. In particular, we found that Aspect-MF with all dynamic aspects outperformed
CTFVSVD in all three datasets on all users.
The analysis of the temporal behaviour of preference aspects and their combinations on the
three datasets showed that different datasets included different temporal patterns, and therefore,
required models with different dynamic aspects. This supported our component-based approach in
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:33

modelling the basic preference aspects and their temporal properties. We also concluded that the
dynamic models are more helpful in cases there is enough training data to discern the temporal
properties. In particular, we concluded that the models proposed in this paper are more successful
in modelling all users, because more time-related data is available for all users than cold-start users,
and therefore the temporal characteristics were extracted more accurately. The analysis of the
robustness of the models with respect to the shortage of training data also revealed that Aspect-MF
was in general more robust than CTFVSVD and TrustSVD. The models were also more robust
for all users than cold-start users, because cold-start users were more sensitive to the inaccurate
predictions.
A direction that we would like to pursue in the future is related to explaining the resulting
recommendations to the users. Explaining the recommendations to the users is believed to improve
transparency and to instill trust in the users. So far we have pursued our main goal in improving the
accuracy of the recommendations, and in this paper we showed how we could achieve significant
improvements by taking the temporal aspects into consideration. As the next step, in particular
we are interested in how we can explain the temporal properties of the trained models to the
users. Furthermore, the component-based structure followed in designing Aspect-MF is generally
beneficial in extracting explanations.
ACKNOWLEDGMENTS
We would like to acknowledge the SunCorp Group for partially funding this project. We would
also like to thank the National eResearch Collaboration Tools and Resources (Nectar) for providing
us with the necessary computational resources to carry out the experiments.
REFERENCES
[1] Susan E Aldrich. 2011. Recommender systems in commercial use. AI Magazine 32, 3 (2011), 28–34.
[2] Linas Baltrunas, Bernd Ludwig, and Francesco Ricci. 2011. Matrix factorization techniques for context aware recommendation. In Proceedings of the fifth ACM conference on Recommender systems. ACM, 301–304.
[3] Sotirios Chatzis. 2014. Dynamic Bayesian Probabilistic Matrix Factorization.. In AAAI. 1731–1737.
[4] Li Chen, Guanliang Chen, and Feng Wang. 2015. Recommender systems based on user reviews: the state of the art.
User Modeling and User-Adapted Interaction 25, 2 (2015), 99–154.
[5] Rafael M D’Addio and Marcelo G Manzato. 2015. A sentiment-based item description approach for kNN collaborative
filtering. In Proceedings of the 30th Annual ACM Symposium on Applied Computing. ACM, 1060–1065.
[6] Guibing Guo, Jie Zhang, and Neil Yorke-Smith. 2015. TrustSVD: Collaborative Filtering with Both the Explicit and
Implicit Influence of User Trust and of Item Ratings.. In AAAI. 123–129.
[7] Guibing Guo, Jie Zhang, and Neil Yorke-Smith. 2016. A Novel Recommendation Model Regularized with User Trust
and Item Ratings. IEEE Transactions on Knowledge and Data Engineering 28, 7 (2016), 1607–1620.
[8] Michael Jahrer, Andreas Töscher, and Robert Legenstein. 2010. Combining predictions for accurate recommender
systems. In Proceedings of the 16th ACM SIGKDD international conference on Knowledge discovery and data mining.
ACM, 693–702.
[9] Mohsen Jamali and Martin Ester. 2010. A matrix factorization technique with trust propagation for recommendation
in social networks. In Proceedings of the fourth ACM conference on Recommender systems. ACM, 135–142.
[10] Alexandros Karatzoglou, Xavier Amatriain, Linas Baltrunas, and Nuria Oliver. 2010. Multiverse recommendation:
n-dimensional tensor factorization for context-aware collaborative filtering. In Proceedings of the fourth ACM conference
on Recommender systems. ACM, 79–86.
[11] Noam Koenigstein, Gideon Dror, and Yehuda Koren. 2011. Yahoo! music recommendations: modeling music ratings
with temporal dynamics and item taxonomy. In Proceedings of the fifth ACM conference on Recommender systems. ACM,
165–172.
[12] Kevin B Korb and Ann E Nicholson. 2010. Bayesian artificial intelligence. CRC press.
[13] Yehuda Koren. 2010. Collaborative filtering with temporal dynamics. Commun. ACM 53, 4 (2010), 89–97.
[14] Yehuda Koren and Robert Bell. 2011. Advances in collaborative filtering. In Recommender systems handbook. Springer,
145–186.
arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:34

Zafari et al.

[15] Yehuda Koren, Robert Bell, and Chris Volinsky. 2009. Matrix factorization techniques for recommender systems.
Computer 42, 8 (2009), 30–37.
[16] Tong Queue Lee, Young Park, and Yong-Tae Park. 2008. A time-based approach to effective recommender systems
using implicit feedback. Expert systems with applications 34, 4 (2008), 3055–3062.
[17] Kevin Lewis, Marco Gonzalez, and Jason Kaufman. 2012. Social selection and peer influence in an online social
network. Proceedings of the National Academy of Sciences 109, 1 (2012), 68–72. https://doi.org/10.1073/pnas.1109739109
arXiv:http://www.pnas.org/content/109/1/68.full.pdf
[18] Ruijiang Li, Bin Li, Cheng Jin, Xiangyang Xue, and Xingquan Zhu. 2011. Tracking User-Preference Varying Speed in
Collaborative Filtering.. In AAAI.
[19] Wenyu Liu, Caihua Wu, Bin Feng, and Juntao Liu. 2015. Conditional preference in recommender systems. Expert
Systems with Applications 42, 2 (2015), 774–788.
[20] Xin Liu and Karl Aberer. 2013. SoCo: a social network aided context-aware recommender system. In Proceedings of the
22nd international conference on World Wide Web. ACM, 781–802.
[21] Cheng Luo and Xiongcai Cai. 2016. Bayesian Wishart matrix factorization. Data Mining and Knowledge Discovery 30,
5 (2016), 1166–1191.
[22] Hao Ma, Haixuan Yang, Michael R Lyu, and Irwin King. 2008. Sorec: social recommendation using probabilistic matrix
factorization. In Proceedings of the 17th ACM conference on Information and knowledge management. ACM, 931–940.
[23] Hao Ma, Dengyong Zhou, Chao Liu, Michael R Lyu, and Irwin King. 2011. Recommender systems with social
regularization. In Proceedings of the fourth ACM international conference on Web search and data mining. ACM,
287–296.
[24] Jing Pan, Zhao Ma, Yanwei Pang, and Yuan Yuan. 2013. Robust probabilistic tensor analysis for time-variant collaborative filtering. Neurocomputing 119 (2013), 139–143.
[25] Ruslan Salakhutdinov and Andriy Mnih. 2008. Bayesian probabilistic matrix factorization using Markov chain Monte
Carlo. In Proceedings of the 25th international conference on Machine learning. ACM, 880–887.
[26] Ruslan Salakhutdinov and Andriy Mnih. 2011. Probabilistic matrix factorization. In NIPS, Vol. 20. 1–8.
[27] Gerhard Widmer and Miroslav Kubat. 1996. Learning in the presence of concept drift and hidden contexts. Machine
learning 23, 1 (1996), 69–101.
[28] Liang Xiang and Qing Yang. 2009. Time-dependent models in collaborative filtering based recommender system. In
Web Intelligence and Intelligent Agent Technologies, 2009. WI-IAT’09. IEEE/WIC/ACM International Joint Conferences on,
Vol. 1. IEEE, 450–457.
[29] Liang Xiong, Xi Chen, Tzu-Kuo Huang, Jeff Schneider, and Jaime G Carbonell. 2010. Temporal collaborative filtering
with bayesian probabilistic tensor factorization. In Proceedings of the 2010 SIAM International Conference on Data
Mining. SIAM, 211–222.
[30] Reza Zafarani, Mohammad Ali Abbasi, and Huan Liu. 2014. Social media mining: an introduction. Cambridge University
Press.
[31] F. Zafari and I. Moser. 2016. Feature-Aware Factorised Collaborative Filtering. In Australasian Joint Conference on
Artificial Intelligence. Springer, 561–569.
[32] F. Zafari and I. Moser. 2017. Modelling Socially-Influenced Conditional Preferences over Feature Values in Recommender
Systems Based on Factorised Collaborative Filtering. Expert Systems with Applications 87 (2017), 98–117. https:
//doi.org/10.1016/j.eswa.2017.05.058
[33] F. Zafari, I. Moser, and R. Rahmani. 2017. Proposing a Highly Accurate Hybrid Component-Based Factorised Preference
Model in Recommender Systems. In Proceedings of the 26th International Joint Conference on Artificial Intelligence
(IJCAI).
[34] Farhad Zafari and Faria Nassiri-Mofakham. 2016. POPPONENT: Highly accurate, individually and socially efficient
opponent preference model in bilateral multi issue negotiations. Artificial Intelligence 237 (2016), 59–91.
[35] Farhad Zafari and Faria Nassiri-Mofakham. 2017. POPPONENT: Highly accurate, individually and socially efficient
opponent preference model in bilateral multi issue negotiations (Extended Abstract). In Proceedings of the 26th
International Joint Conference on Artificial Intelligence (IJCAI).
[36] Farhad Zafari, Faria Nassiri-Mofakham, and Ali Zeinal Hamadani. 2015. DOPPONENT: A socially efficient preference
model of opponent in bilateral multi issue negotiations. Journal of Computing and Security 1, 4 (2015), 283–292.
[37] Yongfeng Zhang, Guokun Lai, Min Zhang, Yi Zhang, Yiqun Liu, and Shaoping Ma. 2014. Explicit factor models for
explainable recommendation based on phrase-level sentiment analysis. In Proceedings of the 37th international ACM
SIGIR conference on Research & development in information retrieval. ACM, 83–92.
[38] Haiyan Zhao, Shengsheng Wang, Qingkui Chen, and Jian Cao. 2015. Probabilistic Matrix Factorization Based on
Similarity Propagation and Trust Propagation for Recommendation. In 2015 IEEE Conference on Collaboration and
Internet Computing (CIC). IEEE, 90–98.

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach
A

1:35

ASPECT-MF TRAINING EQUATIONS

In Aspect-MF, we use gradient descent to optimise Eq. 19. The gradients for the model parameters
are obtained using Eqs. 45 to 66.
1
∂E
∂E R
=
= eu j + λbu |Iu | − 2 buu
∂buu
∂buu

(26)

1
∂E
∂E R
∀tu j ∈ Iut :
=
= eu j + λbu |Iu | − 2 butut
∂butut
∂butut

(27)

1
∂E
∂E R
=
= eu j devu (tu j ) + λbu |Iu | − 2 αu
∂αu
∂αu

(28)

1
∂E
∂E R
=
= eu j (Cu + Cut ) + λbi |J j | − 2 bi j
∂bi j
∂bi j

(29)

1
∂E
∂E R
=
= eu j (Cu + Cut ) + λbi |J j | − 2 bit j Bin(tu j )
∂bit j Bin(tu j )
∂bit j Bin(tu j )

(30)

1
∂E
∂E R
=
= eu j (bi j + bit j Bin(tu j ) ) + λbi |J j | − 2 Cu
∂Cu
∂Cu

(31)

1
∂E
∂E R
=
= eu j (bi j + bit j Bin(tu j ) ) + λbi |J j | − 2 Ctu
∂Ctu
∂Ctu

(32)

∂E
∂E R
∂ET
=
+
∂Puf
∂Puf
∂Puf

(33)

1
∂E R
= eu j (Wuf (tu j)Q jf (tu j) + Zuf (tu j)) + λ P |Iu | − 2 Puf
∂Puf

(34)

Õ
1
∂ET
(1)
= λT |Tu | − 2 Puf + λt η P
euv ωv f
∂Puf

(35)

∀v ∈Tu

∀tu j ∈ Iut :

∂E R
∂ET
∂E
=
+
∂Ptuf t
∂Ptuf t
∂Ptuf t

(36)

1
∂E R
= eu j (Wuf (tu j)Q jf (tu j ) + Zuf (tu j)) + λ P t |Iu | − 2 Ptuf t
∂Ptuf t

(37)

1
λt η P Õ (1)
∂ET
= λT |Tu | − 2 Ptuf t + t
euv ωv f
∂Ptuf t
|Iu | ∀v ∈T
u

(38)

∂E
P
∂αuf

∂E R
P
∂αuf

=

∂E R
P
∂αuf

+

∂ET

(39)

P
∂αuf

P
= eu j devu (tu j )(Wuf (tu j)Q jf (tu j) + Zuf (tu j)) + λ α P |Iu | − 2 αuf
1

(40)

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:36

Zafari et al.

∂ET

P
= λT |Tu | − 2 αuf
+
1

P
∂αuf

Õ
λt η P Õ
(1)
euv ωv f devu (tu j )
t
|Iu | ∀v ∈T
t
u ∀tu j ∈Iu

(41)

∂E R
∂ET
∂E
=
+
∂Wuf
∂Wuf
∂Wuf

(42)

∂E R
= eu j Q jf (tu j)(Wuf (tu j)Q jf (tu j) + Zuf (tu j))
∂Wuf
D
Õ

+ 2Q jf (tu j)

0

(43)

1

(Wuf (tu j)Q jf 0 (tu j) + Zuf 0 (tu j)) + λW |Iu | − 2 Wuf

f =1

Õ
1
∂ET
(2)
= λT |Tu | − 2 Wuf + λt ηW
euv ωv f
∂Wuf

(44)

∂E R
∂ET
∂E
=
+
∀tu j ∈ Iut :
∂W tuf t
∂W tuf t
∂W tuf t

(45)

∀v ∈Tu

∂E R
= eu j Q jf (tu j)(Wuf (tu j)Q jf (tu j ) + Zuf (tu j))
∂W tuf t
+ 2Q jf (tu j)

D
Õ
0

1

(46)

(Wuf (tu j)Q jf 0 (tu j) + Zuf 0 (tu j)) + λW t |Iu | − 2 Wuf

f =1
1
λt ηW Õ (2)
∂ET
euv ωv f
= λT |Tu | − 2 Wuf + t
∂W tuf t
|Iu | ∀v ∈T
u

∂E
W
∂αuf

∂E R
W
∂αuf

=

∂E R
W
∂αuf

+

(47)

∂ET

(48)

W
∂αuf

= eu j devu (tu j )(Wuf (tu j)Q jf (tu j) + Zuf (tu j))
+ 2Q jf (tu j)

D
Õ
0

(49)
(Wuf (tu j)Q jf (tu j) + Zuf (tu j)) + λ α W
0

0

1
W
|Iu | − 2 αuf

f =1

∂ET
W
∂αuf

W
= λT |Tu | − 2 αuf
+
1

Õ
λt ηW Õ
(2)
euv ωv f devu (tu j )
t
|Iu | ∀v ∈T
t
u ∀tu j ∈Iu

∂E
∂E R
∂ET
=
+
∂Zuf
∂Zuf
∂Zuf
D
Õ
∂E R
= eu j (Wuf (tu j)Q jf (tu j) + Zuf (tu j)) + 2
(Wuf (tu j)Q jf 0 (tu j) + Zuf 0 (tu j))
∂Zuf
0
f =1

+ λ Z |Iu |

− 21

Zuf

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

(50)

(51)

(52)

Modelling and Analysis of Temporal Preference Drifts Using A Component-Based
Factorised Latent Approach

1:37

Õ
1
∂ET
(3)
= λT |Tu | − 2 Zuf + λt η Z
euv ωv f
∂Zuf

(53)

∂E
∂E R
∂ET
∀tu j ∈ Iut :
=
+
∂Ztuf t
∂Ztuf t
∂Ztuf t

(54)

∀v ∈Tu

D
Õ
∂E R
=eu j (Wuf (tu j)Q jf (tu j ) + Zuf (tu j)) + 2
(Wuf (tu j)Q jf 0 (tu j) + Zuf 0 (tu j))+
∂Ztuf t
0
f =1

λ Z |Iu |

− 12

Ztuf t

1
λt η Z Õ (3)
∂ET
= λT |Tu | − 2 Ztuf t + t
euv ωv f
∂Ztuf t
|Iu | ∀v ∈T
u

∂E
Z
∂αuf

∂E R
Z
∂αuf

(55)

=

∂E R
Z
∂αuf

+

∂ET

(56)

(57)

Z
∂αuf

= eu j devu (tu j )(Wuf (tu j)Q jf (tu j) + Zuf (tu j))
+2

D
Õ
0

(58)
1
Z
(Wuf (tu j)Q jf 0 (tu j) + Zuf 0 (tu j)) + λ α Z |Iu | − 2 αuf

f =1

∂ET
Z
∂αuf

∀i ∈ Iu :

Z
= λT |Tu | − 2 αuf
+
1

Õ
λt ηZ Õ
(3)
euv ωv f devu (tu j )
t
|Iu | ∀v ∈T
t
u ∀tu j ∈Iu

(59)

1
1
∂E
∂E R
=
= eu j |Iu | − 2 (Wuf Vjf + Zuf ) + (λy |J j | − 2 yif )
∂yif
∂yif

(60)

∂E
∂E R
∂ET
=
+
∂ωv f
∂ωv f
∂ωv f

(61)

∀v ∈ Tu :

1
∂E R
= eu j |Tu | − 2 (W (t)uf Q jf + Z (t)uf )
∂ωv f

1
λt η P Õ (1)
∂ET
= (λT |Tv+ | − 2 )ωv f + t
euv P(tu j )uf
∂ωv f
|Iu |
∀tu j ∈Iut
λt ηW Õ (2)
λt η Z Õ (3)
+ t
euv (1 − W (tu j )uf ) + t
euv Z (tu j )uf
|Iu |
|Iu |
t
t

∀tu j ∈Iu

(62)

(63)

∀tu j ∈Iu

∂E
∂E R
=
= eu j (Wif Vjf + Z if )(Wif 0 Vjf 0 + Z if 0 ) − λY Yf f 0
∂Yf f 0
∂Yf f 0

(64)

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

1:38

Zafari et al.

1 Õ
∂E
∂E R
=
= eu j [Wuf (Puf + |Iu | − 2
yi +
∂Q jf
∂Q jf
∀i ∈Iu
1

|Tu | − 2

Õ
∀v ∈Tu

ωv ) + 2Wuf

D
Õ
0

(65)
1

(Wif 0 Vjf 0 + Z if 0 )Yf f 0 ] + λQ |U j | − 2 Q jf

f =1

where:
eu j = Ru j − Rˆu j

(66)

Therefore, the gradients in Eqs. 45 to 66 will be used to update the values matrices used to capture
socially-influenced drifting conditional feature value preferences using an incremental gradient
descent method.

arXiv, Vol. 1, No. 1, Article 1. Publication date: February 2018.

