commentQuestions {compare}R Documentation

Apply a Commenting Scheme

Description

This function applies a commenting scheme to a set of comparisons to produce a set of comments.

Usage

commentQuestions(result, ...)

Arguments

result

A set of comparison results, as generated by the compareFiles() function.

...

One or more commenting schemes, as generated by the questionComments() function.

Value

A matrix of comments.

Author(s)

Paul Murrell

See Also

questionComments and compareFiles

Examples

modelNames <- c("id", "age", 
                "edu", "class", 
                "IndianMothers")
files <- list.files(system.file("example", package="compare"),
                    pattern="^student[0-9]+[.]R$",
                    full.names=TRUE)

results <- compareFiles(files,
                        modelNames,
                        system.file("example", "model.R", package="compare"),
                        allowAll=TRUE,
                        resultNames=gsub(".+[/]|[.]R", "", files))
q1comments <- questionComments(c("id", "age", "edu", "class"),
                               comments("class",
                                        transformComment("coerced",
                                                         "'class' is a factor!")))
commentQuestions(results, q1comments)

[Package compare version 0.2-6 Index]