transmute_df_into_label: Transmute Degrees-of-Freedom Columns into Variable Labels

View source: R/transmute_df_into_label.R

transmute_df_into_labelR Documentation

Transmute Degrees-of-Freedom Columns into Variable Labels

Description

Takes the output from apa_print() methods and modifies the results table by transmuting information about degrees of freedom into the variable labels of test-statistic columns.

Usage

transmute_df_into_label(x, check_df = TRUE, ...)

df_into_label(x, check_df = TRUE, ...)

## S3 method for class 'apa_results'
transmute_df_into_label(x, check_df = TRUE, ...)

## S3 method for class 'apa_results_table'
transmute_df_into_label(x, check_df = TRUE, ...)

Arguments

x

Either the complete output object created by apa_print() methods, or the table component of such objects.

check_df

Logical. If TRUE (the default), checks if degrees-of-freedom-columns contain non-integer values.

...

further arguments passed from an to other methods

Value

An object of the same class as x, where a redundant column with degrees of freedom has been incorporated into the column label of the column statistic.

Examples

  apa_out <- apa_print(aov(yield ~ N * P, npk))

  # Standard output with separate columns for degrees of freedom:
  apa_out$table

  # Modified output where degrees of freedom are incorporated into the variable
  # label of column 'statistic':
  transmute_df_into_label(apa_out)$table



papaja documentation built on Sept. 29, 2023, 9:07 a.m.