function hook_recommender_info in Recommender API 7.5
extra parameters to consider:
'missing' => how to handle missing data 'none' do nothing 'zero' fill in missing data with zero 'adjusted' skip mice that don't share cheese in common. 'sensitivity' => float. if similarity is smaller enough to be less than a certain value (sensitivity), we just discard those 'lowerbound' => float. if similarity is smaller enough to be less than this value, we just discard those 'duplicate' => how to handle predictions that already exists in mouse-cheese evaluation. 'keep' 'remove' 'incremental' => whether to rebuild the whole similarity matrix, or incrementally update those got changed. 'rebuild', 'refresh'
for slopeone: 'extention' => whether to use 'basic', 'weighted', or 'bipolar' extensions of the algorithm. Please refer to the original research paper. Usually it could just be 'weighted'
Return value
array recommender info array.
1 function implements hook_recommender_info()
Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.
- rec_example_recommender_info in rec_example/
rec_example.module
2 invocations of hook_recommender_info()
- recommender_create_record in ./
recommender.module - views_handler_filter_recommender::get_value_options in ./
recommender.views.inc - Child classes should be used to override this function and set the 'value options', unless 'options callback' is defined as a valid function or static public method to generate these values.
File
- ./
recommender.api.php, line 28 - This file documents the APIs provided by the RecommenderAPI module.
Code
function hook_recommender_info() {
return array(
'rec_example' => array(
'title' => t('Recommender API Example on GroupLens data'),
'algorithm' => 'Item2Item',
'table' => '<BUILTIN>',
// this would help Views figure out which base table to join. currently not used.
'entity_type' => array(
'similarity' => array(
'node',
'node',
),
'prediction' => array(
'users',
'node',
),
),
//'performance' => 'memory',
'preference' => 'score',
),
'rec_example_update' => array(
'title' => t('Recommender API Example on GroupLens data (incremental update)'),
'algorithm' => 'Item2ItemIncrement',
'base_app_name' => 'rec_example',
'table' => '<BUILTIN>',
// this would help Views figure out which base table to join. currently not used.
'entity_type' => array(
'similarity' => array(
'node',
'node',
),
'prediction' => array(
'users',
'node',
),
),
'performance' => 'memory',
'preference' => 'score',
),
);
}