Description Usage Arguments Details Value See Also Examples
View source: R/Evaluate_Predictor.R
The algorithm updates the prediction model according to the current database and then does a n-fold cross validation with the same settings.
1 | Evaluate_Predictor(db, nFold = 5)
|
db |
|
nFold |
|
Hyperparameters for the predictor are read from the storage
table (Params). Then, Update_Predictor
is run
with these parameters.
Table transactions is read according to hyperparameters and INNER JOINed with accounts.
Table personalAccounts is read and INNER JOINed with accounts.
A FeatureExtraction
is done with the tables.
A CV
(cross validation) is done to calculate an error
estimate.
sda::sda.ranking
is run if there are more features than
the maximum number of features
specified in the Hyperparameters. This is a ranking based on
correlation-adjusted t scores.
With this ranking features are selected during the Training
of the predictor.
Table Storage is updated with the resulting Err and Ranking.
If there are to few transactions used for training (per corss validation round), the predcitor might not work. It depends on how well the different types (labels) are represented, but as a rule of thumb there should be a minimum of 20 transactions. So, with a 5-fold cross validation that is at least 100 transactions.
TRUE
if sucessful, otherwise a chr
message
where the algorithm stopped.
Other procedures: Duplicated.Transactions
,
Duplicated
,
Enter.Transactions
, Enter
,
Predict.Transactions
,
Predict
, Read.Transactions
,
Read_csv
, Read
,
Update_Predictor
1 2 3 4 5 6 7 8 9 10 11 12 | db <- "test.db"
Create_testDB(db)
params <- list(
nFeats = 200,
DDL = FALSE,
time = list(start = as.Date("2010-1-1"), end = as.Date("2011-1-1"))
)
InsertBLOB("Params", params, db)
Evaluate_Predictor(db)
err <- SelectBLOB("Err", db)
ranks <- SelectBLOB("Ranking", db)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.