Read the reportable parts of an analysis or quality result
Source:R/accessors.R
sframe_report_accessors.Rdsframe_apa() returns the APA-formatted sentence a result carries.
sframe_flagged() returns the rows a quality report flagged.
Value
sframe_apa() returns a character vector: one element per block, named
by block, for analysis results, and one element for a single report.
sframe_flagged() returns an integer vector of row positions, sorted, each
row once.
Details
Given analysis results, sframe_apa() answers for every block at once, as a
character vector named by block. Given one of the standalone reports that
carry a sentence of their own, an assumption report, a descriptives report,
a missing-data report or a validity report, it returns that single
sentence. A result lacking a sentence gives an empty string, so the shape of
the answer follows the number of blocks asked about.
The sentence is plain text. APA 7 asks for italic Latin statistical symbols,
so italicise t, F, p, r, d and the remaining Latin statistical
symbols after pasting into a manuscript. Numbers are already
APA-formatted, including the APA 7 form .032 for p and a labelled confidence
interval.
sframe_flagged() returns row positions in the response data, as one sorted
vector with each row once, pooling every check the quality report ran:
failed attention checks, straight-lining, excess missingness, timing and
duplicates. Read the report itself for which check flagged a row.
See also
Other Inspect functions:
as.data.frame.sf_choices(),
as.data.frame.sframe(),
as.data.frame.sframe_analysis_results(),
as.data.frame.sframe_assumption_report(),
as.data.frame.sframe_codebook(),
as.data.frame.sframe_descriptives_report(),
as.data.frame.sframe_efa_report(),
as.data.frame.sframe_efa_solution(),
as.data.frame.sframe_item_report(),
as.data.frame.sframe_missing_data_report(),
as.data.frame.sframe_quality_report(),
as.data.frame.sframe_reliability_report(),
as.data.frame.sframe_sample_size_plan(),
as.data.frame.sframe_sensitivity(),
as.data.frame.sframe_validation(),
as.data.frame.sframe_validity_report(),
sf_component_list,
sframe_accessors,
sframe_apa(),
sframe_as_data_frame(),
sframe_flagged(),
sframe_get_attention_checks(),
sframe_get_branches(),
sframe_get_choice_sets(),
sframe_get_items(),
sframe_get_models(),
sframe_get_scales(),
sframe_id(),
sframe_identity,
sframe_is_valid(),
sframe_label(),
sframe_meta(),
sframe_missing_columns(),
sframe_notes(),
sframe_object(),
sframe_problems(),
sframe_subset,
sframe_validation_accessors
Examples
demo <- sframe_demo("tourism_services")
qr <- sframe_quality_results(demo$responses, demo$instrument)
head(sframe_flagged(qr))