MyMediaLite  3.11
Public Member Functions | Properties | List of all members
RatingsChronologicalSplit Class Reference

chronological split for rating prediction More...

Inheritance diagram for RatingsChronologicalSplit:
ISplit< ITimedRatings >

Public Member Functions

 RatingsChronologicalSplit (ITimedRatings ratings, double ratio)
 Create a chronological split of rating prediction data More...
 
 RatingsChronologicalSplit (ITimedRatings ratings, DateTime split_time)
 Create a chronological split of rating prediction data More...
 

Properties

uint NumberOfFolds [get]
 
IList< ITimedRatingsTest [get]
 
IList< ITimedRatingsTrain [get]
 

Detailed Description

chronological split for rating prediction

Chronological splits (splits according to the time of the rating) treat all ratings before a certain time as training ratings, and the ones after that time as test/validation ratings. This kind of split is the most realistic kind of split, because in a real application you also can only use past data to make predictions for the future.

The dataset must not be modified after the split - this would lead to undefined behavior.

Constructor & Destructor Documentation

RatingsChronologicalSplit ( ITimedRatings  ratings,
double  ratio 
)
inline

Create a chronological split of rating prediction data

If ratings have exactly the same date and time, and they are close to the threshold between train and test, there is no guaranteed order between them (ties are broken according to how the sorting procedure sorts the ratings).

Parameters
ratingsthe dataset
ratiothe ratio of ratings to use for validation
RatingsChronologicalSplit ( ITimedRatings  ratings,
DateTime  split_time 
)
inline

Create a chronological split of rating prediction data

Parameters
ratingsthe dataset
split_timethe point in time to use for splitting the data set; everything from that point on will be used for validation

The documentation for this class was generated from the following file: