Predicts the outcomes and puts the predicted values into a SQL table

Argument and Default Value

Feature name for the SQL table.


Given a model (--load_model), this switch will predict the outcomes on the groups given in the outcome table and puts the values into a MySQL table. This is useful for a set of groups that you don't have the outcomes for, but you have a prediction model for it (here are the outcomes we can predict from language). The table created will look like: feat$p_modelType_ARGUMENT$message_table$group_id. If you used ridge for instance, it will look like feat$p_ridg_ARGUMENT$message_table$group_id.

Make sure the features are in the right order (i.e. the order they were put into when creating the model).

For now, you need to make an output table that contains non null values for the outcomes & groups that you want predictions for, cause it uses the --predict_regression code to run this, which is why it also outputs comparisons between the values in the outcome table and the predicted outcomes. This should be changed soon though, so stay tuned!

Other Switches

Required Switches: -d, -g, -t, -f, --outcome_table, --outcomes --load_model and --picklefile Optional Switches: --group_freq_thresh Example Commands ================ .. code:doc:fwflag_block:: python

# Loads the regression model in deleteMe.pickle, and uses the features to predict the ages of the users in # masterstats_andy_r10k, and inserts those values into a table called feat$p_ridg_deleteMe$messages_en$user_id. # Note that it only predicts age for those groups with non null age values in masterstats_andy_r10k. ~/fwInterface.py -d fb20 -t messages_en -g user_id -f 'feat$1gram$messages_en$user_id$16to16$0_01' --outcome_table masterstats_andy_r10k --outcomes age --load_model --picklefile deleteMe.pickle --predict_regression_to_feats deleteMe